[Openmp-commits] [PATCH] D90962: [OpenMP] Fix possible NULL dereferences

Andrey Churbanov via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Tue Nov 10 12:34:54 PST 2020

AndreyChurbanov added a comment.

> I mean for example `__kmp_str_loc_init`, which does gracefully handle ill-formed input (as far as I can tell).
> If it doesn't, let's fix it as well. Either way, we should probably reuse it.

I'd vote for abandoning of this patch, rather than re-using `__kmp_str_loc_init` here.
On one hand the function indeed has all needed checks in place and all needed functionality,
on the other hand it is much heavier, makes a lot of unneeded for metadata reporting actions including expensive memory allocation calls.
So with its re-use the metadata reporting can slow the barriers, I am afraid. And people can finally see distorted execution profile in the tool.

So I'd vote for faster execution here as opposed to elegant coding.
If you are still unhappy with the change, let's abandon this patch.

  rG LLVM Github Monorepo



More information about the Openmp-commits mailing list