Hi Sergii, I built this into mesa 17.3.7 and it seems to solve all the issues I've seen that were mentioned in 101408.
This includes not just the issues with the Mortar, but the other visual artefacts that I've noticed with the player models and with other weapons in the game. Many thanks for digging into this. On 26 March 2018 at 23:22, Sergii Romantsov < sergii.romant...@globallogic.com> wrote: > Hello, Stuart. > Could You, please, test this patch? > > On Mon, Mar 26, 2018 at 3:16 PM, Sergii Romantsov < > sergii.romant...@gmail.com> wrote: > >> Negative deltas are used to fake a range in a large buffer. >> See 900a5c91eeb3 >> "i965: Use negative relocation deltas to minimise vertex uploads" >> >> Gen8+ use 48-bit address relocations so need to extend the sign >> to 64-bit return value. Without it we have higher bits zeroed >> and missing the negavive values. >> Haswell and older use 32-bit deltas so are unaffected by this issue. >> >> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=101408 >> Signed-off-by: Sergii Romantsov <sergii.romant...@globallogic.com> >> Tested-by: Andriy Khulap <andriy.khu...@globallogic.com> >> --- >> src/mesa/drivers/dri/i965/intel_batchbuffer.c | 4 +++- >> 1 file changed, 3 insertions(+), 1 deletion(-) >> >> diff --git a/src/mesa/drivers/dri/i965/intel_batchbuffer.c >> b/src/mesa/drivers/dri/i965/intel_batchbuffer.c >> index d824ff2..128da77 100644 >> --- a/src/mesa/drivers/dri/i965/intel_batchbuffer.c >> +++ b/src/mesa/drivers/dri/i965/intel_batchbuffer.c >> @@ -1124,8 +1124,10 @@ emit_reloc(struct intel_batchbuffer *batch, >> /* Using the old buffer offset, write in what the right data would >> be, in >> * case the buffer doesn't move and we can short-circuit the >> relocation >> * processing in the kernel >> + * >> + * Some target_offsets may be negative, so extend the sign to 64 bits. >> */ >> - return entry->offset + target_offset; >> + return entry->offset + (int64_t)((int32_t)target_offset); >> } >> >> uint64_t >> -- >> 2.7.4 >> >> _______________________________________________ >> mesa-dev mailing list >> mesa-dev@lists.freedesktop.org >> https://lists.freedesktop.org/mailman/listinfo/mesa-dev >> > > > > -- > Sergii Romantsov > GlobalLogic Inc. > www.globallogic.com > -- Stuart Young (aka Cefiar)
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev