yaxunl marked 5 inline comments as done. ================ Comment at: test/Headers/opencl-c-header.cl:50 @@ +49,3 @@ + +// === +// Compile for OpenCL 1.0 for the second time. The module should not be re-created. ---------------- I changed the module to read only. If Clang tries to create a new module, it will fail. Also add a check to make sure module is read.
================ Comment at: test/Headers/opencl-c-header.cl:70 @@ +69,3 @@ +// RUN: %clang_cc1 -triple spir-unknown-unknown -emit-llvm -o - -finclude-default-header -fmodules -fimplicit-module-maps -fmodules-cache-path=%t %s | FileCheck %s +// RUN: %clang_cc1 -triple spir-unknown-unknown -emit-llvm -o - -cl-std=CL2.0 -finclude-default-header -fmodules -fimplicit-module-maps -fmodules-cache-path=%t %s | FileCheck --check-prefix=CHECK20 %s +// RUN: %clang_cc1 -triple amdgcn--amdhsa -emit-llvm -o - -cl-std=CL2.0 -finclude-default-header -fmodules -fimplicit-module-maps -fmodules-cache-path=%t %s | FileCheck --check-prefix=CHECK20 %s ---------------- I added check to the second compilation to make sure module is read, also changed the modules to be read only so that they won't be created again. http://reviews.llvm.org/D20444 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits