This is an archive of the discontinued LLVM Phabricator instance.

Comprehensive static instrumentation (3/3): Runtime and tests
AbandonedPublic

Authored by tdenniston on Jun 16 2016, 12:55 PM.

Details

Summary

This diff encompasses runtime support for CSI in compiler-rt as well as some initial tests.

Diff Detail

Repository
rL LLVM

Event Timeline

tdenniston retitled this revision from to Comprehensive static instrumentation (3/3): Runtime and tests.
tdenniston updated this object.
tdenniston added reviewers: kcc, zhaoqin, bruening.
tdenniston set the repository for this revision to rL LLVM.
tdenniston added a project: Restricted Project.
tdenniston added subscribers: llvm-commits, eugenis, pcc and 2 others.
neboat added a subscriber: neboat.Jun 16 2016, 1:41 PM
kcc added inline comments.Jun 16 2016, 2:22 PM
lib/csi/csi.h
6

does it really need to be C-compatible?
This complicates the interface.

7

avoid extra defines in the interface headers, if you can.

15

CSI_WEAK

29

avoid defines.
not so easy in C, easy in C++

42

watch for spacing around "*"

80

the docs show this struct differently.

100

#endif // CSI_H

lib/csi/csirt.c
18

Please follow the llvm style guides for var/type/field names.

The naming of the interface functions (and types?) is fine, please change the rest.

54

use C++ (new).
But also why do you need to allocate a fixed size buffer?

59

nullptr, here and everywhere

74

I hate realloc.
Not sure if it can be *easily* replaced here.

82

watch for 80 chars

86

watch for {} and single-line statements.

tdenniston abandoned this revision.Jun 27 2016, 7:54 AM

Abandoning. We are resubmitting the CSI patches in smaller increments.