Skip to content
Commit d1d93da7 authored by Ariel Burton's avatar Ariel Burton Committed by Kai Nacke
Browse files

[Clang] Fix __ptr32 arguments passed to builtins

Currently when clang deals with a call to a builtin function that
is supplied with an argument that has an explicit address space
it rewrites the signature of the callee to make the types of
the formal parameters match those of the actual arguments.
This functionality was added to support OpenCL, and was
introduced with commit b919c7d9.

However, this does not work properly for "size" related address
spaces such as those used for __ptr32. This affects platforms
like Microsoft and z/OS.

This change preserves the OpenCL functionality, but will use
the formal parameter types when an address space is size-related.

Reviewed By: akhuang

Differential Revision: https://reviews.llvm.org/D142048
parent dc1c8917
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment