Skip to content

Fix cuda_fp16.h not found issue#834

Merged
lockshaw merged 1 commit intoflexflow:repo-refactorfrom
lockshaw:fix/cuda-fp16-include
Jul 6, 2023
Merged

Fix cuda_fp16.h not found issue#834
lockshaw merged 1 commit intoflexflow:repo-refactorfrom
lockshaw:fix/cuda-fp16-include

Conversation

@lockshaw
Copy link
Collaborator

@lockshaw lockshaw commented Jul 5, 2023

Description of changes:

On machines where the cuda headers were not automatically being searched, a build error would result in utils/fp16.h. This fixes that by explicitly adding the found cuda include directories to the requirements of utils.

Related Issues:

Linked Issues:

  • Issue #

Issues closed by this PR:

Before merging:

  • Did you update the flexflow-third-party repo, if modifying any of the Cmake files, the build configs, or the submodules?

@lockshaw lockshaw requested a review from KateUnger July 5, 2023 04:30
@lockshaw lockshaw changed the base branch from master to repo-refactor July 5, 2023 04:30
@lockshaw lockshaw force-pushed the fix/cuda-fp16-include branch from 96674dc to 068e157 Compare July 5, 2023 07:07
@KateUnger
Copy link
Contributor

@lockshaw Should this PR also fix the build error?

 template <typename T, typename F>
 void inplace_sorted_by(std::vector<T> &v, F const &f) {
-  struct {
-    bool operator()(T const &lhs, T const &rhs) { return f(lhs, rhs); }
-  } custom_comparator;
+  auto custom_comparator = [&](T const &lhs, T const &rhs) -> bool {
+    return f(lhs, rhs);
+  };
   
   std::sort(v.begin(), v.end(), custom_comparator);

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.

Build Error in Runtime (cuda_fp16.h)

2 participants