From: bugzilla-daemon@freedesktop.org Subject: [Bug 65873] R600/SI: Cannot select store with truncate to 32-bit Date: Thu, 27 Jun 2013 17:26:53 +0000 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1407990605==" Return-path: Received: from culpepper.freedesktop.org (unknown [131.252.210.165]) by gabe.freedesktop.org (Postfix) with ESMTP id 14BAEE5CB5 for ; Thu, 27 Jun 2013 10:26:53 -0700 (PDT) In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org Errors-To: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org To: dri-devel@lists.freedesktop.org List-Id: dri-devel@lists.freedesktop.org --===============1407990605== Content-Type: multipart/alternative; boundary="1372354013.D0e721.1660"; charset="us-ascii" --1372354013.D0e721.1660 Date: Thu, 27 Jun 2013 17:26:53 +0000 MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" https://bugs.freedesktop.org/show_bug.cgi?id=65873 --- Comment #7 from Tom Stellard --- The SI backend needs to be fixed so it can handle zext i64 loads, but there is also a bug in libclc. The vload implementation assumes pointer types are 32-bit: define <2 x i32> @__clc_vload2_impl_i32__global(i32 %offset, i32 addrspace(1)* nocapture %addr) nounwind readonly alwaysinline { %1 = ptrtoint i32 addrspace(1)* %addr to i32 %2 = add i32 %1, %offset %3 = inttoptr i32 %2 to <2 x i32> addrspace(1)* %4 = load <2 x i32> addrspace(1)* %3, align 4, !tbaa !3 ret <2 x i32> %4 } Pointers on SI are 64-bit. This ptrtoint, add, inttoptr sequence should be replaced with a getelementptr and a bitcast. -- You are receiving this mail because: You are the assignee for the bug. --1372354013.D0e721.1660 Date: Thu, 27 Jun 2013 17:26:53 +0000 MIME-Version: 1.0 Content-Type: text/html; charset="UTF-8"

Comment # 7 on bug 65873 from
The SI backend needs to be fixed so it can handle zext i64 loads, but there is
also a bug in libclc.  The vload implementation assumes pointer types are
32-bit:

define <2 x i32> @__clc_vload2_impl_i32__global(i32 %offset,  i32 addrspace(1)*
nocapture %addr) nounwind readonly alwaysinline {
  %1 = ptrtoint i32 addrspace(1)* %addr to i32
  %2 = add i32 %1, %offset
  %3 = inttoptr i32 %2 to <2 x i32> addrspace(1)*
  %4 = load <2 x i32> addrspace(1)* %3, align 4, !tbaa !3
  ret <2 x i32> %4
}

Pointers on SI are 64-bit.  This ptrtoint, add, inttoptr sequence should be
replaced with a getelementptr and a bitcast.


You are receiving this mail because:
  • You are the assignee for the bug.
--1372354013.D0e721.1660-- --===============1407990605== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ dri-devel mailing list dri-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/dri-devel --===============1407990605==--