Skip to content
This repository has been archived by the owner on May 1, 2023. It is now read-only.

Releases: facebookarchive/profilo

release-b5c4f63: Remove CHECKs

15 Dec 01:21
Compare
Choose a tag to compare
Summary:
CHECK calls can and will fail when run from a bizarro context (e.g., signal
handler). Unfortunately, they do a lot of disallowed things like allocating
buffers and fancy string formatting. None of this is safe.

I believe this is behind a fair amount of instability in Loom.

Reviewed By: aandreyeu

Differential Revision: D6573635

fbshipit-source-id: 03638f5babb12900ee6a014f7976e197eaa04e64

release-342a150: Fix signal handling on unwinding error

13 Dec 23:01
Compare
Choose a tag to compare
Summary:
`compare_exchange_strong` takes `expected` by reference and updates it on
failure with the actual value in the atomic storage.

Therefore, we need to recreate `expected` before each call or we'll never find
the faulty slot.

Reviewed By: aandreyeu

Differential Revision: D6558209

fbshipit-source-id: 1c6532637167e8f1da8c9f30c3b32480afb870f7

release-b68e586: Propagate multiprocess aborts to main process

12 Dec 18:52
Compare
Choose a tag to compare
Differential Revision: D6503999

fbshipit-source-id: a3e50c5d6b7e9f1b2b9cba5fe25c49dfb37baee3

release-684a607: Inline provider names

12 Dec 21:27
Compare
Choose a tag to compare
Summary: Provider names are a config implementation detail.

Differential Revision: D6546693

fbshipit-source-id: 1803b69d7a1004a306756c645ab6f16a37b073aa

release-5d37f41: Eliminate race condition on thread id in Sampling Profiler

12 Dec 21:59
Compare
Choose a tag to compare
Summary:
This revision eliminates `thread id` out of the race condition on slot reuse by including the `thread id` into the actual slot state for uniqueness and CAS updates.
Previously we used two fields to check the state and the owner of a slot: `state` and `tid`.
Now tid is combined with state for `BUSY` case when thread is working on collecting a sample:
`StackSlotState::BUSY` -> `StackSlotState::BUSY | (tid << 16)`.

The race condition:
**Step 3**  Initial state: 2 slots and 2 threads (tid = 1,2). //Thread 1// collecting a sample atm. //Thread 2// is not in a signal handler.
//Slot 1// = {state = FREE, tid = 1, owner = none}
//Slot 2// = {state = BUSY, tid = 1, owner = Thread 1}
**Step 1**  //Thread 2// took the //Slot 1// and updated the state to `BUSY` but the `tid` field has not been updated yet. //Thread 1// collecting a sample atm and crashes with `SIGSEGV`.
//Slot 1// = {state = BUSY, tid = 1, owner = Thread 2}
//Slot 2// = {state = BUSY, tid = 1, owner = Thread 1}
**Step 2**  `sigcatch_handler` catches the `SIGSEGV` of the //Thread 1// and finds the //Slot 1// first as corresponding to the signal and the caused thread(but //Slot 1// is taken by //Thread 2//).
//Slot 1// = {state = FREE, tid = 1, owner = Thread 2}
//Slot 2// = {state = BUSY, tid = 1, owner = Thread 1}
**Step 3**  //Thread 2// continues collecting sample and at the moment it tries to update slot it finds it in `FREE` state instead of `BUSY` and aborts.
//Slot 1// = {state = FREE, tid = 2, owner = Thread 2}

Reviewed By: BurntBrunch

Differential Revision: D6545736

fbshipit-source-id: 31b93a1f307873cb6fa87ab9c7f043d3b199d9b1

release-f1edf45: Fix assorted C++ nits caught by stricter warnings from clang-5.0

09 Dec 01:58
Compare
Choose a tag to compare
Summary: Offload the gcc-compatible fixes from the diff that cuts-over to building fb4a with clang.

Differential Revision: D6525454

fbshipit-source-id: 02ce4d8f84ebbce6a4605f0b64b822e11defe20a

release-e8f4f44: Revert D6155682: Use clang-5.0 -Oz

08 Dec 17:53
Compare
Choose a tag to compare
Summary:
This reverts commit 2f64e742f4dc44be171274c2ad0a41fb1e7079d7

bypass-lint

Differential Revision: D6155682

fbshipit-source-id: 9139ed14e0d24784bf25b2783e364a511173ab83

release-5276081: Remove unnecessary SparseArray with provider names

08 Dec 21:15
Compare
Choose a tag to compare
Summary: This was never useful.

Reviewed By: ricardorey10

Differential Revision: D6504393

fbshipit-source-id: 4b4e8a5b9a3034770ac090702e1aa281e29cc692

release-4691635: Calculate the section name's length by the buf size instead of strlen()

08 Dec 11:52
Compare
Choose a tag to compare
Summary: FBSystrace's logs are not null-terminated, which makes Atrace get a wrong length of the section name using strlen method and print weird characters to Loom traces.

Reviewed By: BurntBrunch

Differential Revision: D6496836

fbshipit-source-id: 2440140e99031ae21c8e114a5d372c76f908322e

release-884baff

07 Dec 01:18
Compare
Choose a tag to compare
Remove facebook/