utest: fix i386 system long ctz fail.

Submitted by Pan Xiuli on Jan. 3, 2017, 8:43 a.m.

Details

Message ID 53C176F57F7E09459ED90EC4B7F4D8DC51008319@SHSMSX103.ccr.corp.intel.com
State New
Headers show
Series "utest: fix i386 system long ctz fail." ( rev: 2 ) in Beignet

Not browsing as part of any series.

Commit Message

Pan Xiuli Jan. 3, 2017, 8:43 a.m.
LGTM.

-----Original Message-----
From: Beignet [mailto:beignet-bounces@lists.freedesktop.org] On Behalf Of Yang Rong

Sent: Tuesday, January 3, 2017 6:14 PM
To: beignet@lists.freedesktop.org
Cc: Yang, Rong R <rong.r.yang@intel.com>
Subject: [Beignet] [PATCH] utest: fix i386 system long ctz fail.

Use 1ll as uint64_t.

Signed-off-by: Yang Rong <rong.r.yang@intel.com>

---
 utests/compiler_ctz.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--
2.1.4

_______________________________________________
Beignet mailing list
Beignet@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/beignet

Patch hide | download patch | download mbox

diff --git a/utests/compiler_ctz.cpp b/utests/compiler_ctz.cpp index 88f2109..d84fdad 100644
--- a/utests/compiler_ctz.cpp
+++ b/utests/compiler_ctz.cpp
@@ -19,7 +19,7 @@  void test(const char *kernel_name)
 
   OCL_MAP_BUFFER(0);
   for (uint32_t i = 0; i < n; ++i) {
-      ((U*)buf_data[0])[i] = 1l << i;
+      ((U*)buf_data[0])[i] = 1ll << i;
       if(i == sizeof(U)*8)
         ((U*)buf_data[0])[i] = 0;
   }