summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorMatt Turner <[email protected]>2014-05-18 11:16:26 -0700
committerMatt Turner <[email protected]>2014-05-24 23:03:24 -0700
commit424303db7f9ad47524ec5f3e38500620c16ab5a1 (patch)
tree9b361753edfe953aa5aade68f7e72990380e6e29 /src/mesa
parent99af02fb1778a425f1f3d211018d294b8d3b2245 (diff)
i965/fs: Use next_insn_offset rather than nr_insn.
Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/i965/brw_fs_generator.cpp4
-rw-r--r--src/mesa/drivers/dri/i965/gen8_fs_generator.cpp4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_fs_generator.cpp b/src/mesa/drivers/dri/i965/brw_fs_generator.cpp
index 6cff9b34ef9..d1d271933c6 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_generator.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs_generator.cpp
@@ -1796,12 +1796,12 @@ fs_generator::generate_assembly(exec_list *simd8_instructions,
if (simd16_instructions) {
/* align to 64 byte boundary. */
- while ((p->nr_insn * sizeof(struct brw_instruction)) % 64) {
+ while (p->next_insn_offset % 64) {
brw_NOP(p);
}
/* Save off the start of this SIMD16 program */
- prog_data->prog_offset_16 = p->nr_insn * sizeof(struct brw_instruction);
+ prog_data->prog_offset_16 = p->next_insn_offset;
brw_set_compression_control(p, BRW_COMPRESSION_COMPRESSED);
diff --git a/src/mesa/drivers/dri/i965/gen8_fs_generator.cpp b/src/mesa/drivers/dri/i965/gen8_fs_generator.cpp
index aec9421e853..bab1208a217 100644
--- a/src/mesa/drivers/dri/i965/gen8_fs_generator.cpp
+++ b/src/mesa/drivers/dri/i965/gen8_fs_generator.cpp
@@ -1284,11 +1284,11 @@ gen8_fs_generator::generate_assembly(exec_list *simd8_instructions,
if (simd16_instructions) {
/* Align to a 64-byte boundary. */
- while ((nr_inst * sizeof(gen8_instruction)) % 64)
+ while (next_inst_offset % 64)
NOP();
/* Save off the start of this SIMD16 program */
- prog_data->prog_offset_16 = nr_inst * sizeof(gen8_instruction);
+ prog_data->prog_offset_16 = next_inst_offset;
struct annotation_info annotation;
memset(&annotation, 0, sizeof(annotation));