[PATCH] [InstCombine] Canonicalize addrspacecast between different element types
Philip Reames
listmail at philipreames.com
Wed Jun 4 10:59:09 PDT 2014
I'm reading this commit out of context, so this question might not make
a lot of sense. If that's the case, please ignore.
If we are canonicalizing addrspacecasts to only convert between address
spaces and not types, is there any value in having addrspacecast be a
superset of bitcast to begin with? Why not have the frontend emit both
the addrspacecast and the bitcast itself?
Philip
On 06/03/2014 06:48 PM, Matt Arsenault wrote:
> LGTM
>
> ================
> Comment at: lib/Transforms/InstCombine/InstCombineCasts.cpp:1925-1926
> @@ +1924,4 @@
> +
> + // Putting bitcast before addrspacecast helps NVPTXFavorNonGenericAddrSpaces
> + // to fold the addrspacecast into load/store.
> + Value *NewBitCast = Builder->CreateBitCast(Src, MidTy);
> ----------------
> I would remove the comment about a specific target pass
>
> http://reviews.llvm.org/D4013
>
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
More information about the llvm-commits
mailing list