[GPU] Disassemble memexport exports

This commit is contained in:
DrChat
2018-04-08 18:02:39 -05:00
parent 1d4fa80eac
commit e6524aa497
3 changed files with 41 additions and 6 deletions

View File

@@ -1147,14 +1147,15 @@ void ShaderTranslator::ParseAluVectorInstruction(
} else if (is_vertex_shader()) {
switch (dest_num) {
case 32:
i.result.storage_target = InstructionStorageTarget::kExportAddress;
break;
case 33:
case 34:
case 35:
case 36:
case 37:
// TODO: Memexport registers
i.result.storage_target = InstructionStorageTarget::kNone;
i.result.storage_index = 0;
i.result.storage_index = dest_num - 33;
i.result.storage_target = InstructionStorageTarget::kExportData;
break;
case 62:
i.result.storage_target = InstructionStorageTarget::kPosition;
@@ -1198,14 +1199,15 @@ void ShaderTranslator::ParseAluVectorInstruction(
i.result.storage_index = 3;
break;
case 32:
i.result.storage_target = InstructionStorageTarget::kExportAddress;
break;
case 33:
case 34:
case 35:
case 36:
case 37:
// TODO: Memexport registers
i.result.storage_target = InstructionStorageTarget::kNone;
i.result.storage_index = 0;
i.result.storage_index = dest_num - 33;
i.result.storage_target = InstructionStorageTarget::kExportData;
break;
case 61:
i.result.storage_target = InstructionStorageTarget::kDepth;
@@ -1303,6 +1305,17 @@ void ShaderTranslator::ParseAluScalarInstruction(
: InstructionStorageAddressingMode::kStatic;
} else if (is_vertex_shader()) {
switch (dest_num) {
case 32:
i.result.storage_target = InstructionStorageTarget::kExportAddress;
break;
case 33:
case 34:
case 35:
case 36:
case 37:
i.result.storage_index = dest_num - 33;
i.result.storage_target = InstructionStorageTarget::kExportData;
break;
case 62:
i.result.storage_target = InstructionStorageTarget::kPosition;
break;
@@ -1344,6 +1357,17 @@ void ShaderTranslator::ParseAluScalarInstruction(
i.result.storage_target = InstructionStorageTarget::kColorTarget;
i.result.storage_index = 3;
break;
case 32:
i.result.storage_target = InstructionStorageTarget::kExportAddress;
break;
case 33:
case 34:
case 35:
case 36:
case 37:
i.result.storage_index = dest_num - 33;
i.result.storage_target = InstructionStorageTarget::kExportData;
break;
case 61:
i.result.storage_target = InstructionStorageTarget::kDepth;
break;