Page MenuHomePhabricator

chill (Momchil Velikov)
User

Projects

User does not belong to any projects.

User Details

User Since
May 24 2017, 3:29 AM (173 w, 2 d)

Recent Activity

Today

chill added a comment to D85649: [AArch64] PAC/BTI code generation for LLVM generated functions.

It looks like the only value that makes sense is Error - any other policy (existing or not) would potentially lead to meaningfully different code generated with or without LTO.

Fri, Sep 18, 3:25 AM · Restricted Project

Yesterday

chill planned changes to D85649: [AArch64] PAC/BTI code generation for LLVM generated functions.

Thank you for your comments. I'd like to have the same behaviour with or without LTO, which is apparently not the case with this patch.

Thu, Sep 17, 1:30 AM · Restricted Project

Wed, Sep 16

chill accepted D80791: [AArch64] Generate .note.gnu.property based on module flags..
Wed, Sep 16, 8:14 AM · Restricted Project, Restricted Project
chill added a comment to D85649: [AArch64] PAC/BTI code generation for LLVM generated functions.

Ping.

Wed, Sep 16, 3:37 AM · Restricted Project
chill added a comment to D86478: [ARM][CMSE] Issue an error if passing arguments through memory across security boundary.

Ping

Wed, Sep 16, 3:37 AM · Restricted Project

Tue, Sep 8

chill added a comment to D85649: [AArch64] PAC/BTI code generation for LLVM generated functions.

Ping,

Tue, Sep 8, 3:07 AM · Restricted Project

Mon, Sep 7

chill committed rGeb482afaf5bb: Reduce the number of memory allocations when displaying (authored by chill).
Reduce the number of memory allocations when displaying
Mon, Sep 7, 9:05 AM
chill closed D86088: Reduce the number of memory allocations when displaying a warning about clobbering reserved registers (NFC)..
Mon, Sep 7, 9:05 AM · Restricted Project
chill accepted D87134: [SelectionDAG] memcpy expansion of const volatile struct ignores const zero.

LGTM.

Mon, Sep 7, 3:34 AM · Restricted Project
chill added a comment to D86478: [ARM][CMSE] Issue an error if passing arguments through memory across security boundary.

Ping.

Mon, Sep 7, 1:52 AM · Restricted Project

Wed, Sep 2

chill accepted D81930: [AArch64] Add -mmark-bti-property flag..

LGTM. It'd be nice if we could get someone non-Arm to have a look too. though.

Wed, Sep 2, 7:31 AM · Restricted Project, Restricted Project
chill added a comment to D80791: [AArch64] Generate .note.gnu.property based on module flags..

LGTM, as soon as D85649 is accepted (so they stay in sync).

Wed, Sep 2, 7:12 AM · Restricted Project, Restricted Project
chill updated the diff for D85649: [AArch64] PAC/BTI code generation for LLVM generated functions.

Emit function-level LLVM IR attributes only when there's a GCC-style function attribute and be explicit with enabling/disabling.
Fixed an error where "none" in deferred to module attributes, instead of overriding them.

Wed, Sep 2, 6:03 AM · Restricted Project
chill added a comment to D84502: [AArch64][GlobalISel] Implement __builtin_return_address for PAC-RET.

No, not yet.

Wed, Sep 2, 1:06 AM · Restricted Project

Tue, Sep 1

chill planned changes to D85649: [AArch64] PAC/BTI code generation for LLVM generated functions.

In addition to the disabling of BTI in D81251, there's an issue that we explicitly disable BTI via branch-protection=none, the attribute would just be missing and we'll pick up the module attributes, which is not what we want.

Tue, Sep 1, 4:47 AM · Restricted Project
chill added inline comments to D81251: [AArch64] Add BTI to CFI jumptables..
Tue, Sep 1, 4:38 AM · Restricted Project

Thu, Aug 27

chill added a comment to D86088: Reduce the number of memory allocations when displaying a warning about clobbering reserved registers (NFC)..

Ping?

Thu, Aug 27, 3:18 AM · Restricted Project

Tue, Aug 25

chill added inline comments to D81930: [AArch64] Add -mmark-bti-property flag..
Tue, Aug 25, 1:22 AM · Restricted Project, Restricted Project

Mon, Aug 24

chill requested review of D86478: [ARM][CMSE] Issue an error if passing arguments through memory across security boundary.
Mon, Aug 24, 10:59 AM · Restricted Project
chill added a comment to D85649: [AArch64] PAC/BTI code generation for LLVM generated functions.

Does this conflict with D80791?

It does, we're using different module attributes.

Mon, Aug 24, 9:19 AM · Restricted Project

Fri, Aug 21

chill added a comment to D80791: [AArch64] Generate .note.gnu.property based on module flags..

In D85649 I suggested a different version of module flags, which is a bit nicer to use, e.g. one can say just

getModuleFlag("sign-return-address-with-bkey") != nullptr

instead of a) checking for the flag presence, b) getting its value and c) comparing it to a set of strings, which is
way too verbose.

Fri, Aug 21, 4:25 AM · Restricted Project, Restricted Project

Thu, Aug 20

chill added a comment to D84502: [AArch64][GlobalISel] Implement __builtin_return_address for PAC-RET.

Thanks!

Thu, Aug 20, 12:47 AM · Restricted Project
chill accepted D75044: [AArch64] __builtin_return_address for PAuth..
Thu, Aug 20, 12:47 AM · Restricted Project, Restricted Project

Aug 19 2020

chill added a comment to D85649: [AArch64] PAC/BTI code generation for LLVM generated functions.

Ping?

Aug 19 2020, 3:49 AM · Restricted Project

Aug 18 2020

chill added a comment to D84502: [AArch64][GlobalISel] Implement __builtin_return_address for PAC-RET.

Ping?

Aug 18 2020, 7:53 AM · Restricted Project

Aug 17 2020

chill requested review of D86088: Reduce the number of memory allocations when displaying a warning about clobbering reserved registers (NFC)..
Aug 17 2020, 9:17 AM · Restricted Project

Aug 12 2020

chill added a comment to D85649: [AArch64] PAC/BTI code generation for LLVM generated functions.

Is there a test for no module attributes + function level attribute enabling pac/bti that tests that just that function gets the proper handling?

Aug 12 2020, 5:16 AM · Restricted Project
chill updated the diff for D85649: [AArch64] PAC/BTI code generation for LLVM generated functions.
Aug 12 2020, 5:10 AM · Restricted Project

Aug 11 2020

chill added a comment to D80791: [AArch64] Generate .note.gnu.property based on module flags..

it is not useful to have a bti annotated function unless everything else is bti compatible too: it is all or nothing per elf module.

This is false. Some functions in an elf module could be in a guarded region, some in a non-guarded region. Some function may always
be called in a "BTI-safe" way, which may be unknown to the compiler.

Right now the elf and all of the text sections considered BTI enabled or not. The dynamic linkers/loaders can't support this
use case without additional information to be encoded somewhere (and specified). To support such we need to consider grouping/align to page
boundaries these functions in the linker because BTI could be controlled by flags in PTE.
With the current spec this usecase is not supported in this way. The user have to link the BTI protected code into another elf.
Side note: The force-bti linker option can't work with half BTI enabled objects.

Aug 11 2020, 8:08 AM · Restricted Project, Restricted Project
chill added a comment to D80791: [AArch64] Generate .note.gnu.property based on module flags..
In D80791#2209624, @nsz wrote:

I would prefer to avoid the situation where the markings of two otherwise identical files were different,
depending on how the files were produced, no matter if it was a common or a special case.

i don't see why it is desirable to silently get marking on an object file if function definitions happen to be bti compatible in it:

Aug 11 2020, 5:27 AM · Restricted Project, Restricted Project
chill updated the diff for D84502: [AArch64][GlobalISel] Implement __builtin_return_address for PAC-RET.

Well, it wasn't completely broken, just a little bit :D

Aug 11 2020, 4:58 AM · Restricted Project
chill planned changes to D84502: [AArch64][GlobalISel] Implement __builtin_return_address for PAC-RET.
Aug 11 2020, 3:02 AM · Restricted Project

Aug 10 2020

chill requested review of D84502: [AArch64][GlobalISel] Implement __builtin_return_address for PAC-RET.
Aug 10 2020, 12:21 PM · Restricted Project
chill updated the diff for D84502: [AArch64][GlobalISel] Implement __builtin_return_address for PAC-RET.

Updated the patch to unconditionally include PAC stripping instructions, NOP-space ones to non-NON-space ones, depending on
whether v8.3-a (soo to be '+pa') feature.

Aug 10 2020, 12:19 PM · Restricted Project
chill added a comment to D80791: [AArch64] Generate .note.gnu.property based on module flags..

I would prefer to avoid the situation where the markings of two otherwise identical files were different,
depending on how the files were produced, no matter if it was a common or a special case.

Aug 10 2020, 9:35 AM · Restricted Project, Restricted Project
chill added a comment to D80791: [AArch64] Generate .note.gnu.property based on module flags..
In D80791#2206853, @nsz wrote:

i think that cannot work.

the implementation is free to inject arbitrary code into
user code so if the user does not tell the implementation
that it wants the entire tu to be bti safe then non-bti
code can end up in there. (e.g. ctor of an instrumentation
that is not realated to any particular function with the
bti marking)

Aug 10 2020, 8:15 AM · Restricted Project, Restricted Project
chill added a reviewer for D85649: [AArch64] PAC/BTI code generation for LLVM generated functions: tellenbach.
Aug 10 2020, 7:01 AM · Restricted Project
chill requested review of D85649: [AArch64] PAC/BTI code generation for LLVM generated functions.
Aug 10 2020, 6:59 AM · Restricted Project
chill added a comment to D80791: [AArch64] Generate .note.gnu.property based on module flags..
In D80791#2196598, @nsz wrote:

the assumption is that the intended branch protection is implied via cmdline flags for the tu and function attributes are only used in source code for some hack.

I don't share this assumption. I find it just as valid to control the PAC/BTI with things like:

#ifdef ENABLE_BTI
#define BTI_FUNC __attribute__((target("branch-protection=bti")))
#else
#define BTI_FUNC
Aug 10 2020, 3:03 AM · Restricted Project, Restricted Project

Aug 7 2020

chill requested changes to D81930: [AArch64] Add -mmark-bti-property flag..
Aug 7 2020, 3:25 AM · Restricted Project, Restricted Project

Aug 5 2020

chill added a comment to D75181: [AArch64] Handle BTI/PAC in case of generated functions..

I don't see any other alternative option, I'm open to any other idea.

My original idea was to pass options to LLVM. I'll come up with a patch in a day or two (if it works) and then we'll see.

Aug 5 2020, 12:16 PM · Restricted Project, Restricted Project
chill added inline comments to D80791: [AArch64] Generate .note.gnu.property based on module flags..
Aug 5 2020, 8:57 AM · Restricted Project, Restricted Project
chill added a comment to D84502: [AArch64][GlobalISel] Implement __builtin_return_address for PAC-RET.

I'm in favour of changing these patches to unconditionally emit XPACLRI (i.e. HINT #whatever).

Aug 5 2020, 8:40 AM · Restricted Project

Aug 4 2020

chill added a comment to D75181: [AArch64] Handle BTI/PAC in case of generated functions..

This approach looks way too hackish to me with multiple opposing attributes ("sign-return-address" vs. "ignore-sign-return-address")
and some convoluted logic to resolve the contradiction.

Aug 4 2020, 4:29 AM · Restricted Project, Restricted Project
chill added a comment to D80791: [AArch64] Generate .note.gnu.property based on module flags..

If any function has the attribute "sign-return-address", then the output note
section should have PAC bit set. The return address signing is completely local
to the function, and functions with or without return address signing can be
freely mixed with each other.

That is true PAC and non-PAC functions can be mixed.
Does one function makes the "all executable sections" pac-ret enabled?

Aug 4 2020, 4:25 AM · Restricted Project, Restricted Project
chill added inline comments to D77565: [AArch64] Remove implicit landing pads..
Aug 4 2020, 3:54 AM · Restricted Project
chill added a comment to D82949: [Driver][ARM] Disable bf16 when hardware FP support is missing.

Is this patch needed anymore?

Aug 4 2020, 3:36 AM · Restricted Project

Jul 31 2020

chill added inline comments to D84502: [AArch64][GlobalISel] Implement __builtin_return_address for PAC-RET.
Jul 31 2020, 3:23 AM · Restricted Project
chill added a comment to D75044: [AArch64] __builtin_return_address for PAuth..

Let's postpone this just for a little bit, to settle on an approach to depth > 0.

Jul 31 2020, 3:05 AM · Restricted Project, Restricted Project
chill requested changes to D75044: [AArch64] __builtin_return_address for PAuth..

Let's postpone this just for a little bit, to settle on an approach to depth > 0.

Jul 31 2020, 3:04 AM · Restricted Project, Restricted Project
chill added a reviewer for D75044: [AArch64] __builtin_return_address for PAuth.: ab.
Jul 31 2020, 3:03 AM · Restricted Project, Restricted Project
chill added a reviewer for D75181: [AArch64] Handle BTI/PAC in case of generated functions.: ab.
Jul 31 2020, 3:02 AM · Restricted Project, Restricted Project

Jul 30 2020

chill committed rGef4e66543541: [AArch64] Fix operand definitions of XPACI/XPACD (authored by chill).
[AArch64] Fix operand definitions of XPACI/XPACD
Jul 30 2020, 7:32 AM
chill closed D84298: [AArch64] Fix operand definitions of XPACI/XPACD.
Jul 30 2020, 7:32 AM · Restricted Project

Jul 29 2020

chill added inline comments to D84502: [AArch64][GlobalISel] Implement __builtin_return_address for PAC-RET.
Jul 29 2020, 8:38 AM · Restricted Project
chill updated the diff for D84502: [AArch64][GlobalISel] Implement __builtin_return_address for PAC-RET.
Jul 29 2020, 8:35 AM · Restricted Project
chill accepted D82948: [Driver][ARM] Disable unsupported features when nofp arch extension is used.

LGTM, thanks!

Jul 29 2020, 4:04 AM · Restricted Project, Restricted Project

Jul 24 2020

Herald added a project to D84502: [AArch64][GlobalISel] Implement __builtin_return_address for PAC-RET: Restricted Project.
Jul 24 2020, 2:42 AM · Restricted Project

Jul 23 2020

chill accepted D75044: [AArch64] __builtin_return_address for PAuth..

LGTM. Thanks!

Jul 23 2020, 10:21 AM · Restricted Project, Restricted Project
Herald added a project to D84395: [AArch64] Fix a machine verifier ICE when using __builtin_return_address with return address sign and authentication: Restricted Project.
Jul 23 2020, 5:10 AM · Restricted Project

Jul 22 2020

chill added reviewers for D84298: [AArch64] Fix operand definitions of XPACI/XPACD: samparker, danielkiss.
Jul 22 2020, 1:47 AM · Restricted Project
Herald added a project to D84298: [AArch64] Fix operand definitions of XPACI/XPACD: Restricted Project.
Jul 22 2020, 1:44 AM · Restricted Project
chill added a comment to D75044: [AArch64] __builtin_return_address for PAuth..

The issue is that the definition of the instructions XPAC{D,I} is incorrect: it does not mention at all the operand to those insns.

Err, they do mention the operand, but only as an input one, it should be input/output.

Jul 22 2020, 1:30 AM · Restricted Project, Restricted Project

Jul 21 2020

chill added a comment to D75044: [AArch64] __builtin_return_address for PAuth..

I'm afraid the patch does not work yet. For example, when the following program

Jul 21 2020, 3:43 PM · Restricted Project, Restricted Project
chill added inline comments to D82948: [Driver][ARM] Disable unsupported features when nofp arch extension is used.
Jul 21 2020, 5:45 AM · Restricted Project, Restricted Project
chill added a comment to D80791: [AArch64] Generate .note.gnu.property based on module flags..

I don't think this behaviour is correct with regard to the specification (AAELF64 2020Q2):

Jul 21 2020, 4:24 AM · Restricted Project, Restricted Project

Jul 2 2020

chill added inline comments to D82948: [Driver][ARM] Disable unsupported features when nofp arch extension is used.
Jul 2 2020, 8:37 AM · Restricted Project, Restricted Project
chill added inline comments to D82948: [Driver][ARM] Disable unsupported features when nofp arch extension is used.
Jul 2 2020, 1:01 AM · Restricted Project, Restricted Project

Jul 1 2020

chill added reviewers for D82948: [Driver][ARM] Disable unsupported features when nofp arch extension is used: efriedma, DavidSpickett.
Jul 1 2020, 12:26 PM · Restricted Project, Restricted Project
chill added a comment to D82948: [Driver][ARM] Disable unsupported features when nofp arch extension is used.

Needs a regression test. This patch and the dependent patch clash, better with a single patch.

Jul 1 2020, 12:26 PM · Restricted Project, Restricted Project

Jun 23 2020

chill committed rGadf7973fd35d: [ARM] Describe defs/uses of VLLDM and VLSTM (authored by chill).
[ARM] Describe defs/uses of VLLDM and VLSTM
Jun 23 2020, 8:32 AM
chill closed D81586: [ARM] Describe defs/uses of VLLDM and VLSTM .
Jun 23 2020, 8:31 AM · Restricted Project
chill added a comment to D81586: [ARM] Describe defs/uses of VLLDM and VLSTM .

Thanks!

Jun 23 2020, 1:00 AM · Restricted Project

Jun 22 2020

chill updated the diff for D81586: [ARM] Describe defs/uses of VLLDM and VLSTM .
Jun 22 2020, 9:07 AM · Restricted Project
chill committed rG75b0bbca1d0c: [LTO] Use StringRef instead of C-style strings in setCodeGenDebugOptions (authored by chill).
[LTO] Use StringRef instead of C-style strings in setCodeGenDebugOptions
Jun 22 2020, 3:44 AM
chill closed D82033: [LTO] Use StringRef instead of C-style strings in setCodeGenDebugOptions.
Jun 22 2020, 3:43 AM · Restricted Project

Jun 19 2020

chill updated the diff for D82033: [LTO] Use StringRef instead of C-style strings in setCodeGenDebugOptions.
Jun 19 2020, 3:44 AM · Restricted Project
chill added a comment to D81586: [ARM] Describe defs/uses of VLLDM and VLSTM .

PIng.

Jun 19 2020, 1:02 AM · Restricted Project

Jun 18 2020

chill accepted D81837: [ARM][bfloat] Removing lowering of bfloat arguments and returns from Clang's CodeGen.
Jun 18 2020, 3:14 AM · Restricted Project
chill added a comment to D82033: [LTO] Use StringRef instead of C-style strings in setCodeGenDebugOptions.

Yeah, I'd prefer that, but then I'm hesitant to change APIs.

Jun 18 2020, 12:30 AM · Restricted Project

Jun 17 2020

chill created D82033: [LTO] Use StringRef instead of C-style strings in setCodeGenDebugOptions.
Jun 17 2020, 11:18 AM · Restricted Project

Jun 16 2020

chill added a comment to D81837: [ARM][bfloat] Removing lowering of bfloat arguments and returns from Clang's CodeGen.

Pretty straightforward, LGTM. I'd suggest rewording the title (presumably commit message summary) into something like "Do not coerce bfloat arguments and returns to integers", as we're obviously still lowering C and C++ to LLVM LR.§§

Jun 16 2020, 11:00 AM · Restricted Project

Jun 15 2020

chill added inline comments to D81746: [AArch64] Fix BTI instruction emission..
Jun 15 2020, 7:33 AM · Restricted Project
chill added inline comments to D81746: [AArch64] Fix BTI instruction emission..
Jun 15 2020, 7:33 AM · Restricted Project
chill added a reviewer for D81837: [ARM][bfloat] Removing lowering of bfloat arguments and returns from Clang's CodeGen: chill.
Jun 15 2020, 7:00 AM · Restricted Project

Jun 12 2020

chill updated the diff for D81586: [ARM] Describe defs/uses of VLLDM and VLSTM .

Updated to take into account liveness of registers. Whenever we blanket push registers, the live ones are ordinary operands,
the dead ones are Undef operands.

Jun 12 2020, 8:07 AM · Restricted Project

Jun 10 2020

chill added inline comments to D81586: [ARM] Describe defs/uses of VLLDM and VLSTM .
Jun 10 2020, 12:49 PM · Restricted Project
chill updated subscribers of D80716: [AArch64]: BFloat Load/Store Intrinsics&CodeGen.
Jun 10 2020, 11:40 AM · Restricted Project, Restricted Project
chill added inline comments to D80716: [AArch64]: BFloat Load/Store Intrinsics&CodeGen.
Jun 10 2020, 11:08 AM · Restricted Project, Restricted Project
chill created D81586: [ARM] Describe defs/uses of VLLDM and VLSTM .
Jun 10 2020, 9:56 AM · Restricted Project
chill added inline comments to D80716: [AArch64]: BFloat Load/Store Intrinsics&CodeGen.
Jun 10 2020, 9:56 AM · Restricted Project, Restricted Project
chill added inline comments to D80716: [AArch64]: BFloat Load/Store Intrinsics&CodeGen.
Jun 10 2020, 8:44 AM · Restricted Project, Restricted Project

May 15 2020

chill accepted D79693: [test][ARM][CMSE] Use clang_cc1 in arm_cmse.h tests.

LGTM, thank you.

May 15 2020, 3:02 AM · Restricted Project

May 14 2020

chill added a comment to D79693: [test][ARM][CMSE] Use clang_cc1 in arm_cmse.h tests.

I see.

May 14 2020, 10:16 AM · Restricted Project
chill committed rGbc2e572f51da: Re-commit: [ARM] CMSE code generation (authored by chill).
Re-commit: [ARM] CMSE code generation
May 14 2020, 9:44 AM
chill closed D76518: [ARM] CMSE code generation.
May 14 2020, 9:44 AM · Restricted Project
chill added a comment to D79693: [test][ARM][CMSE] Use clang_cc1 in arm_cmse.h tests.

I'm sorry, I don't understand the issue. Certainly it's the compiler (driver) responsibility to setup include paths according to the selected target.
How do you trigger a problem?

May 14 2020, 9:10 AM · Restricted Project

May 7 2020

chill updated the diff for D76518: [ARM] CMSE code generation.

The last version of the patch broke compilation with expensive checks - the machine verifier
reported a score of lifetime errors.
In this update, we are more precise with the RegState flags when creating instructions
to save/restore/clear registers around non-secure calls and before return to non-secure state.

May 7 2020, 6:12 AM · Restricted Project
chill requested review of D76518: [ARM] CMSE code generation.
May 7 2020, 6:12 AM · Restricted Project

May 5 2020

chill committed rGfb18dffaeb58: Revert "[ARM] CMSE code generation" (authored by chill).
Revert "[ARM] CMSE code generation"
May 5 2020, 11:21 AM