From 3fb9712906562eb7f7ad872f9ba615055e4f9540 Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Sat, 21 Sep 2019 13:41:06 +0100 Subject: [PATCH] add DCT transforms --- simple_v_extension/specification/mv.x.rst | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/simple_v_extension/specification/mv.x.rst b/simple_v_extension/specification/mv.x.rst index 617ad289f..f0d770bce 100644 --- a/simple_v_extension/specification/mv.x.rst +++ b/simple_v_extension/specification/mv.x.rst @@ -159,4 +159,20 @@ output: -Transforms for DCT https://opencores.org/websvn/filedetails?repname=mpeg2fpga&path=%2Fmpeg2fpga%2Ftrunk%2Frtl%2Fmpeg2%2Fidct.v +https://opencores.org/websvn/filedetails?repname=mpeg2fpga&path=%2Fmpeg2fpga%2Ftrunk%2Frtl%2Fmpeg2%2Fidct.v + +Transforms for DCT +======= +:: + + __m128i T0 = _mm_unpacklo_epi32(I0, I1); + __m128i T1 = _mm_unpacklo_epi32(I2, I3); + __m128i T2 = _mm_unpackhi_epi32(I0, I1); + __m128i T3 = _mm_unpackhi_epi32(I2, I3); + + /* Assigning transposed values back into I[0-3] */ + I0 = _mm_unpacklo_epi64(T0, T1); + I1 = _mm_unpackhi_epi64(T0, T1); + I2 = _mm_unpacklo_epi64(T2, T3); + I3 = _mm_unpackhi_epi64(T2, T3); + -- 2.30.2