nishihei

Problem (Bug?) with Function Call with Constant Buffer

Discussion created by nishihei on Aug 2, 2009
Latest reply on Aug 2, 2009 by nishihei

I cannot compile the attached brook+ code. The error message is following:

WARNING: ASSERT(GetResultSymbol().IsValid() + mDataTypeValue.IsValid() >= 1) failed
While processing <buffer>:182
In compiler at AST::DelayedLookup::ResolveSymbols()[astdelayedlookup.cpp:139]
  *mName = __gatherStreamShape_b
Message: unknown symbol

WARNING: ASSERT(GetResultSymbol().IsValid() + mDataTypeValue.IsValid() >= 1) failed
While processing <buffer>:182
In compiler at AST::DelayedLookup::ResolveSymbols()[astdelayedlookup.cpp:139]
  *mName = __gatherBufferShape_b
Message: unknown symbol

ERROR: ASSERT(errorCount==0) failed
While processing <buffer>:199
In compiler at AST::Root::CompileShaderToStream()[astroot.cpp:157]
  errorCount = 2
Message: Unknown Symbols exist
Aborting...
Problem with compiling C:\Users\nishihei\AppData\Local\Temp\brc1DE4.tmp\Temp_bad_addr.hlsl
Error--:cal back end failed to compile kernel "bad"

This problem happens when a program calls a function with a constant buffer parameter. How can I do in order to avoid this problem?

kernel float4 inner(float4 b[1], float i) { return b[i]; } kernel void bad(out float4 a<>, float4 b[1]) { a = inner(b, indexof(a).x); }

Outcomes