[Beignet] [PATCH 1/2] Fix a re-schedule issue of scratch write
Zhigang Gong
zhigang.gong at gmail.com
Fri Aug 9 01:09:05 PDT 2013
LGTM, will push it soon. Thanks for the patch.
On Fri, Aug 09, 2013 at 01:23:40PM +0800, Ruiling Song wrote:
> As scratchMsgHeader+1 will be re-used as scratch write payload.
> So, scratchMsgHeader+1 will be first spilled out.
> Add the scratch write dependency to keep scratch write in order.
> this fix a failure(compiler_box_blur_float) when spilling.
>
> Signed-off-by: Ruiling Song <ruiling.song at intel.com>
> ---
> backend/src/backend/gen_insn_scheduling.cpp | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/backend/src/backend/gen_insn_scheduling.cpp b/backend/src/backend/gen_insn_scheduling.cpp
> index 0b720b7..2e0f175 100644
> --- a/backend/src/backend/gen_insn_scheduling.cpp
> +++ b/backend/src/backend/gen_insn_scheduling.cpp
> @@ -467,6 +467,11 @@ namespace gbe
> tracker.addDependency(node, index);
> }
>
> + // write-after-write in scratch memory
> + if (insn.opcode == SEL_OP_SPILL_REG) {
> + const uint32_t index = tracker.getIndex(0xff);
> + tracker.addDependency(node, index);
> + }
>
> // Consider barriers and wait are writing memory (local and global)
> if (insn.opcode == SEL_OP_BARRIER ||
> --
> 1.7.9.5
>
> _______________________________________________
> Beignet mailing list
> Beignet at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/beignet
More information about the Beignet
mailing list