AArch64: Correction for LP64
In the Intra16x16PlanePrediction function, a u32 (unsigned 32-bit
integer) was being used for the "i" variable, and being used with a
value of 7 in the loop "for (i = 0, b = 0; i < 8; i++)" to access the
"above[6-i]" location where "above" is defined as "u8 *". Because "i"
was unsigned there was no sign extension on use with the __LP64__
64-bit pointer, so rather than 0xFFFFFFFF being treated as -1, it was
treated as 4,292,967,295 and that resulted in a SIGSEGV at an invalid
address. By changing the type of "i" to an i32 (signed 32-bit integer)
the expected sign extension occurs and the value is treated as -1.
This change fixes android.media.cts.DecoderTest#testCodeBasicH264 on
64-bit platforms
Change-Id: I85df58b0dc1d39f89ab421d04ab5481356520f0c
Signed-off-by: Marcus Oakland <marcus.oakland@arm.com>
Loading
Please register or sign in to comment