Skip to content

Commit

Permalink
Resolve rendering issues on Broadwell iGPUs
Browse files Browse the repository at this point in the history
  • Loading branch information
educovas committed Oct 6, 2023
1 parent 27e3230 commit 5c9fe86
Show file tree
Hide file tree
Showing 73 changed files with 21,820 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundleExecutable</key>
<string>AppleIntelBDWGraphicsMTLDriver</string>
<key>CFBundleGetInfoString</key>
<string>AppleIntelBDWGraphicsMTLDriver 18.8.4 10</string>
<key>CFBundleIdentifier</key>
<string>com.apple.driver.AppleIntelBDWGraphicsMTLDriver</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>Intel g7.5 Metal Driver</string>
<key>CFBundlePackageType</key>
<string>BNDL</string>
<key>CFBundleShortVersionString</key>
<string>18.8.4</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>18.0.8</string>
<key>ComputeFeatureList</key>
<dict>
<key>CLHangOnL3ParityErr</key>
<integer>0</integer>
<key>ComputeSSKernelDebugEnable</key>
<integer>0</integer>
</dict>
<key>Development</key>
<dict>
<key>ClampMaxWorkGroupSizeTo1024Disable</key>
<integer>0</integer>
<key>HizDisable</key>
<integer>0</integer>
</dict>
<key>NSPrincipalClass</key>
<string>MTLIGAccelDevice</string>
</dict>
</plist>
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
BNDL????
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
// Bottleneck analysis functions
// They can reference both derived counters and dependent raw counters
// APIs:
// ReportProblem(confidence, problem, severity) -> problemId
// where: severity is one of SEVERITY_HIGH, SEVERITY_MEDIUM, SEVERITY_LOW
// AddProblemSubItem(problemId, description[, resourceLink])
// where: resourceLink is optional and one of "VertexShader", "FragmentShader", "Kernel", "BoundResources", "Attachments"


function is_short_draw()
{
return (GPU_BusyTics < 15000)
}

function analysis_memory_bound()
{
// No Analysis for very short draws
if(is_short_draw())
{
return
}
// see if there is a problem
if(GTRequestQueueFull > 80)
{
var problemId = ReportProblem(1.0, "Memory bandwidth bound", SEVERITY_HIGH)
AddProblemSubItem(problemId, "Reduce overall use of memory bandwidth")
}
else if (DRAMBW > 15.0)
{
var confidence = DRAMBW > 18.0 ? 0.8 : 0.5;
var problemId = ReportProblem(confidence, "Memory bandwidth bound", SEVERITY_MEDIUM)
AddProblemSubItem(problemId, "Reduce overall use of memory bandwidth")
}
}

function analysis_pbe_bound()
{
if(is_short_draw())
{
return
}
if (PixelsWrittenPerClock > 4.0)
{
var confidence = PixelsWrittenPerClock > 8.0 ? 1.0 : 0.5
var severity = PixelsWrittenPerClock > 8.0 ? SEVERITY_MEDIUM : SEVERITY_LOW
var problemId = report_problem(confidence, "Pixel rate bound", severity)
AddProblemSubItem(problemId, "Consider decreasing the size of attachments or the number of MRTs if possible", "Attachments")
}
}

function analysis_shader_bound()
{
if(is_short_draw())
{
return
}

if ((ShaderCoreActive + ShaderCoreStall)> 90.0)
{
if (ShaderCoreActive > ShaderCoreStall)
{
var outputStr = ""
var guideStr = ""
var resourceLink = ""

// Either VS or PS bound
if (PixelCost > VertexCost)
{
outputStr = "Fragment shader bound";
guideStr = "Reduce amount of work in the fragment shader"
resourceLink = "FragmentShader"
}
else
{
outputStr = "Vertex shader bound"
guideStr = "Reduce amount of work in the vertex shader"
resourceLink = "VertexShader"
}
var problemId = ReportProblem(0.8, outputStr, SEVERITY_HIGH)
AddProblemSubItem(problemId, guideStr, resourceLink)
}
else if (ShaderCoreStall > 50)
{
if(TextureUnitStalled > 75)
{
var problemId = ReportProblem(0.8, "Texture Unit bound", SEVERITY_HIGH)
AddProblemSubItem(problemId, "Consider reducing the texture sizes or take fewer samples in the shader", "BoundResources")
}
}
}
}

function analysis_vertex_bound()
{
if(is_short_draw())
{
return
}

if (VerticesPerClock > 1.0)
{
var confidence = VerticesPerClock > 2.0 ? 0.8 : 0.5;
var severity = VerticesPerClock > 2.0 ? SEVERITY_MEDIUM : SEVERITY_LOW

var problemId = ReportProblem(confidence, "Low vertex rate" /* problem */, severity)
AddProblemSubItem(problemId, "Consider reducing the number of vertices")
}
}
Loading

0 comments on commit 5c9fe86

Please sign in to comment.