void
fs_generator::generate_code(exec_list *instructions)
{
- if (unlikely(debug_flag)) {
- if (prog) {
- fprintf(stderr,
- "Native code for %s fragment shader %d (SIMD%d dispatch):\n",
- prog->Label ? prog->Label : "unnamed",
- prog->Name, dispatch_width);
- } else if (fp) {
- fprintf(stderr,
- "Native code for fragment program %d (SIMD%d dispatch):\n",
- fp->Base.Id, dispatch_width);
- } else {
- fprintf(stderr, "Native code for blorp program (SIMD%d dispatch):\n",
- dispatch_width);
- }
- }
-
int start_offset = p->next_insn_offset;
struct annotation_info annotation;
annotation.ann);
if (unlikely(debug_flag)) {
+ if (prog) {
+ fprintf(stderr,
+ "Native code for %s fragment shader %d (SIMD%d dispatch):\n",
+ prog->Label ? prog->Label : "unnamed",
+ prog->Name, dispatch_width);
+ } else if (fp) {
+ fprintf(stderr,
+ "Native code for fragment program %d (SIMD%d dispatch):\n",
+ fp->Base.Id, dispatch_width);
+ } else {
+ fprintf(stderr, "Native code for blorp program (SIMD%d dispatch):\n",
+ dispatch_width);
+ }
+
const struct gl_program *prog = fp ? &fp->Base : NULL;
dump_assembly(p->store, annotation.ann_count, annotation.ann,
void
vec4_generator::generate_code(exec_list *instructions)
{
- if (unlikely(debug_flag)) {
- if (shader_prog) {
- fprintf(stderr, "Native code for %s vertex shader %d:\n",
- shader_prog->Label ? shader_prog->Label : "unnamed",
- shader_prog->Name);
- } else {
- fprintf(stderr, "Native code for vertex program %d:\n", prog->Id);
- }
- }
-
struct annotation_info annotation;
memset(&annotation, 0, sizeof(annotation));
brw_compact_instructions(p, 0, annotation.ann_count, annotation.ann);
if (unlikely(debug_flag)) {
+ if (shader_prog) {
+ fprintf(stderr, "Native code for %s vertex shader %d:\n",
+ shader_prog->Label ? shader_prog->Label : "unnamed",
+ shader_prog->Name);
+ } else {
+ fprintf(stderr, "Native code for vertex program %d:\n", prog->Id);
+ }
+
dump_assembly(p->store, annotation.ann_count, annotation.ann,
brw, prog, brw_disassemble);
ralloc_free(annotation.ann);
void
gen8_fs_generator::generate_code(exec_list *instructions)
{
- if (unlikely(INTEL_DEBUG & DEBUG_WM)) {
- if (prog) {
- fprintf(stderr,
- "Native code for %s fragment shader %d (SIMD%d dispatch):\n",
- shader_prog->Label ? shader_prog->Label : "unnamed",
- shader_prog->Name, dispatch_width);
- } else if (fp) {
- fprintf(stderr,
- "Native code for fragment program %d (SIMD%d dispatch):\n",
- prog->Id, dispatch_width);
- } else {
- fprintf(stderr, "Native code for blorp program (SIMD%d dispatch):\n",
- dispatch_width);
- }
- }
-
struct annotation_info annotation;
memset(&annotation, 0, sizeof(annotation));
annotation_finalize(&annotation, next_inst_offset);
if (unlikely(INTEL_DEBUG & DEBUG_WM)) {
+ if (prog) {
+ fprintf(stderr,
+ "Native code for %s fragment shader %d (SIMD%d dispatch):\n",
+ shader_prog->Label ? shader_prog->Label : "unnamed",
+ shader_prog->Name, dispatch_width);
+ } else if (fp) {
+ fprintf(stderr,
+ "Native code for fragment program %d (SIMD%d dispatch):\n",
+ prog->Id, dispatch_width);
+ } else {
+ fprintf(stderr, "Native code for blorp program (SIMD%d dispatch):\n",
+ dispatch_width);
+ }
+
dump_assembly(store, annotation.ann_count, annotation.ann, brw, prog,
gen8_disassemble);
ralloc_free(annotation.ann);
void
gen8_vec4_generator::generate_code(exec_list *instructions)
{
- if (unlikely(debug_flag)) {
- if (shader_prog) {
- fprintf(stderr, "Native code for %s vertex shader %d:\n",
- shader_prog->Label ? shader_prog->Label : "unnamed",
- shader_prog->Name);
- } else {
- fprintf(stderr, "Native code for vertex program %d:\n", prog->Id);
- }
- }
-
struct annotation_info annotation;
memset(&annotation, 0, sizeof(annotation));
annotation_finalize(&annotation, next_inst_offset);
if (unlikely(debug_flag)) {
+ if (shader_prog) {
+ fprintf(stderr, "Native code for %s vertex shader %d:\n",
+ shader_prog->Label ? shader_prog->Label : "unnamed",
+ shader_prog->Name);
+ } else {
+ fprintf(stderr, "Native code for vertex program %d:\n", prog->Id);
+ }
+
dump_assembly(store, annotation.ann_count, annotation.ann,
brw, prog, gen8_disassemble);
ralloc_free(annotation.ann);