[all-commits] [llvm/llvm-project] b14220: [lldb][X86] Fix setting target features in ClangEx...
Daniil Kovalev via All-commits
all-commits at lists.llvm.org
Sat Mar 2 02:09:59 PST 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: b14220e075fe47f4d61632e80a6d0a4a955a7c97
https://github.com/llvm/llvm-project/commit/b14220e075fe47f4d61632e80a6d0a4a955a7c97
Author: Daniil Kovalev <dkovalev at accesssoftek.com>
Date: 2024-03-02 (Sat, 02 Mar 2024)
Changed paths:
M lldb/source/Plugins/ExpressionParser/Clang/ClangExpressionParser.cpp
Log Message:
-----------
[lldb][X86] Fix setting target features in ClangExpressionParser (#82364)
Currently, for x86 and x86_64 triples, "+sse" and "+sse2" are appended
to `Features` vector of `TargetOptions` unconditionally. This vector is
later reset in `TargetInfo::CreateTargetInfo` and filled using info from
`FeaturesAsWritten` vector, so previous modifications of the `Features`
vector have no effect. For x86_64 triple, we append "sse2"
unconditionally in `X86TargetInfo::initFeatureMap`, so despite the
`Features` vector reset, we still have the desired sse features enabled.
The corresponding code in `X86TargetInfo::initFeatureMap` is marked as
FIXME, so we should not probably rely on it and should set desired
features properly in `ClangExpressionParser`.
This patch changes the vector the features are appended to from
`Features` to `FeaturesAsWritten`. It's not reset later and is used to
compute resulting `Features` vector.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list