On Tue, 10 Sep 2024 20:53:46 GMT, Gerard Ziemski <gziem...@openjdk.org> wrote:
>> Please review this cleanup, where we rename `MEMFLAGS` to `MemTag`. >> >> `MEMFLAGS` implies that we can use more than one at the same time, but those >> are exclusive values, so `MemTag` is a more suitable name. >> >> This fix also includes a cleanup of all the related function/template >> parameter names and local variable names. >> >> Testing is pending... >> >> Note: there is more history in old closed PRs >> [https://github.com/openjdk/jdk/pull/20497](https://github.com/openjdk/jdk/pull/20497) >> and >> [https://github.com/openjdk/jdk/pull/20472](https://github.com/openjdk/jdk/pull/20472) > > Gerard Ziemski has updated the pull request incrementally with one additional > commit since the last revision: > > Coleen's feedback Are we sure we want `mt` for non-type parameter name in templates? We have these existing patterns already in our code: src/hotspot/share/utilities/growableArray.hpp:803:template <typename E, MemTag MT> src/hotspot/share/utilities/stack.hpp:54:template <class E, MemTag MT> class StackIterator; src/hotspot/share/utilities/concurrentHashTable.inline.hpp:78:template <typename CONFIG, MemTag MT> src/hotspot/share/utilities/chunkedList.hpp:31:template <class T, MemTag MT> class ChunkedList : public CHeapObj<MT> src/hotspot/share/gc/g1/g1BatchedTask.hpp:32:template <typename E, MemTag MT> src/hotspot/share/gc/shared/taskqueue.hpp:119:template <unsigned int N, MemTag MT> src/hotspot/share/gc/shared/taskqueue.hpp:327:template <class E, MemTag MT, unsigned int N = TASKQUEUE_SIZE> src/hotspot/share/gc/shenandoah/shenandoahTaskqueue.hpp:40:template<class E, MemTag MT, unsigned int N = TASKQUEUE_SIZE> src/hotspot/share/nmt/arrayWithFreeList.hpp:34:template<typename E, MemTag MT> With mt they would look like: src/hotspot/share/utilities/growableArray.hpp:803:template <typename E, MemTag mt> src/hotspot/share/utilities/stack.hpp:54:template <class E, MemTag mt> class StackIterator; src/hotspot/share/utilities/concurrentHashTable.inline.hpp:78:template <typename CONFIG, MemTag mt> src/hotspot/share/utilities/chunkedList.hpp:31:template <class T, MemTag mt> class ChunkedList : public CHeapObj<mt> src/hotspot/share/gc/g1/g1BatchedTask.hpp:32:template <typename E, MemTag mt> src/hotspot/share/gc/shared/taskqueue.hpp:119:template <unsigned int N, MemTag mt> src/hotspot/share/gc/shared/taskqueue.hpp:327:template <class E, MemTag mt, unsigned int N = TASKQUEUE_SIZE> src/hotspot/share/gc/shenandoah/shenandoahTaskqueue.hpp:40:template<class E, MemTag mt, unsigned int N = TASKQUEUE_SIZE> src/hotspot/share/nmt/arrayWithFreeList.hpp:34:template<typename E, MemTag mt> So `MT` or `mt` for non-type parameter name in templates, or should I punt on this particular change and leave it for a followup? ------------- PR Comment: https://git.openjdk.org/jdk/pull/20872#issuecomment-2343769766