From 2b5cda137f84ebd73de462d19ca9cb74b280bb38 Mon Sep 17 00:00:00 2001 From: Alyssa Rosenzweig Date: Wed, 27 Feb 2019 05:40:55 +0000 Subject: [PATCH] panfrost/midgard: Preview for data hazards If a selected unit causes a data hazard, the whole block gets cut short. So, we preview for data hazards _while_ selecting units. Signed-off-by: Alyssa Rosenzweig Tested-by: Tomeu Vizoso = UNIT_VADD) segment_size = 0; - /* Check for data hazards */ - int has_hazard = false; - - for (int s = 0; s < segment_size; ++s) - if (!can_run_concurrent_ssa(segment[s], ains)) - has_hazard = true; - - if (has_hazard) + if (midgard_has_hazard(segment, segment_size, ains)) break; /* We're good to go -- emit the instruction */ -- 2.30.2