Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add blas runtime activity #1324

Merged
merged 16 commits into from
Jul 16, 2023
Merged

add blas runtime activity #1324

merged 16 commits into from
Jul 16, 2023

Conversation

ZuseZ4
Copy link
Member

@ZuseZ4 ZuseZ4 commented Jul 8, 2023

No description provided.

Copy link
Member

@wsmoses wsmoses left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a test?

@ZuseZ4
Copy link
Member Author

ZuseZ4 commented Jul 8, 2023

test does not show the expected changes yet, looking into why.

Copy link
Member

@wsmoses wsmoses left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a test?

enzyme/tools/enzyme-tblgen/enzyme-tblgen.cpp Outdated Show resolved Hide resolved
@ZuseZ4
Copy link
Member Author

ZuseZ4 commented Jul 12, 2023

@wsmoses In the case of !RuntimeActivity, nothing changes.
In the case of RuntimeActivity, I do have currently 2 BB for each variable that is marked as active.
The first BB is always entered and based on a previous ptr-comparison it will then either enter the corresponding
implementation BB, or it will move to the first BB of the next potentially active variable, where it again will branch
based on the ptr comparison result.

We do have all the ptr comparison results available beforehand, so I guess we could try to do more math to just have one BB for each active variable and just jump into the runtime-active bb, if you think that this is worth it?

@ZuseZ4 ZuseZ4 enabled auto-merge (squash) July 16, 2023 15:42
@ZuseZ4
Copy link
Member Author

ZuseZ4 commented Jul 16, 2023

auto-merging, because with the latest diffUse update it now passes all tests.
If we need larger changes for blas diffUse, let's make them sepeartely

@ZuseZ4 ZuseZ4 merged commit 87e98bf into main Jul 16, 2023
54 of 65 checks passed
@ZuseZ4 ZuseZ4 deleted the tg-blas-runtime-ta branch July 16, 2023 16:44
; RUN: if [ %llvmver -lt 16 ]; then %opt < %s %loadEnzyme -enzyme -S | FileCheck %s; fi
; RUN: %opt < %s %newLoadEnzyme -passes="enzyme" -enzyme-preopt=false -S | FileCheck %s
; RUN: if [ %llvmver -lt 16 ]; then %opt < %s %loadEnzyme -enzyme -enzyme-runtime-activity=1 -S | FileCheck %s; fi
; RUN: %opt < %s %newLoadEnzyme -passes="enzyme" -enzyme-preopt=false -enzyme-runtime-activity=1 -S | FileCheck %s
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ZuseZ4 we should error if forward mode runtime activity is requetsed (rather than silently doing the wrong thing, like here).

MilesCranmer pushed a commit to MilesCranmer/Enzyme that referenced this pull request Jul 24, 2024
* add complex sqrt

* fixes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants