[PATCH] D30015: [OpenMP] Add arch-specific directory to search path

Jonas Hahnfeld via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Feb 16 23:44:59 PST 2017


Hahnfeld added inline comments.


================
Comment at: test/Driver/arch-specific-libdir-rpath.c:6
+// -rpath only gets added during native compilation
+// REQUIRES: native
+//
----------------
mgorny wrote:
> Hahnfeld wrote:
> > pirama wrote:
> > > pirama wrote:
> > > > I feel this test is fragile.  Any idea how to further restrict and require that the default target triple has linux and one of i386, x86_64, arm, aarch64?
> > > > 
> > > > I could create sub-dirs for all archs returned by Triple::getArchTypeName (llvm/lib/Support/Triple.cpp) but it seems overkill.
> > > I've restricted the test to just x86_64-linux.
> > Instead of `REQUIRES`, you should probably add `-target x86_64-unknown-linux`
> Hmm, I don't see any good solution for this. Looking at the code, the host triple is hardcoded, so you'd indeed have to either restrict the test to triples matching LLVM_HOST_TRIPLE. Or maybe add a command-line option to override the host triple.
Sorry, I missed that it's cross-compiling then. `x86_64` is in that case probably the best thing to do because it's most widespread, also among the buildbots.


https://reviews.llvm.org/D30015





More information about the cfe-commits mailing list