Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

opt should raise an error for unsupported target triples. #15398

Open
atrick opened this issue Jan 22, 2013 · 0 comments
Open

opt should raise an error for unsupported target triples. #15398

atrick opened this issue Jan 22, 2013 · 0 comments
Labels
bugzilla Issues migrated from bugzilla tools:opt

Comments

@atrick
Copy link
Contributor

atrick commented Jan 22, 2013

Bugzilla Link 15026
Version trunk
OS All
Depends On #15397
CC @atrick,@jryans,@RKSimon

Extended Description

opt currently attempts to load target information for the target triple specified in the bitcode. If the triple does not match a known target, it silently uses unknown target information. This can cause subtle changes in compiler behavior that are difficult to track down.

A better approach would be for opt to enforce that a backend exists for the specified triple.

Like llc, -mtriple could be used to override the target triple, providing a way to bypass the error.

For example, prior to r172534, the behavior of this test changed dependning on whether the host compiler had built the X86 backend. The test failed with a native ARM-only compiler:
test/Transforms/LoopStrengthReduce/post-inc-icmpzero.ll

Fixing this behavior requires cleaning up the test cases, see #15397 .

@llvmbot llvmbot transferred this issue from llvm/llvm-bugzilla-archive Dec 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugzilla Issues migrated from bugzilla tools:opt
Projects
None yet
Development

No branches or pull requests

1 participant