Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update the documentation and implementation of
OpcodeCounter
In #35, `-O1` was added to the instructions for building `input_for_cc.bc` (i.e. the sample input for the `OpcodeCounter` pass). Unfortunately, `-O1` causes all instructions to be optimized away and hence there's nothing to print for the `OpcodeCounter` pass. This patch fixes that by restoring the original instruction for building `input_for_cc.bc` . In order to work around `optnone` (the original rationale behind adding `-O1` in the previous patch), `isRequired()` [1] is added to the implementation of `OpcodeCounter.` Fixes #38 [1] https://llvm.org/docs/WritingAnLLVMNewPMPass.html#required-passes
- Loading branch information