RFR: 8183569: Assert the same limits are used in parse_xss and globals.hpp [v6]
Ioi Lam
iklam at openjdk.java.net
Tue Mar 2 23:26:28 UTC 2021
> We have the following in Arguments::parse_xss():
>
> const julong min_ThreadStackSize = 0;
> const julong max_ThreadStackSize = 1 * M;
> const julong min_size = min_ThreadStackSize * K;
> const julong max_size = max_ThreadStackSize * K;
>
> which duplicates the min/max range specified in globals.hpp:
>
> product_pd(intx, ThreadStackSize, \
> "Thread Stack Size (in Kbytes)") \
> range(0, 1 * M) \
>
> I added an API to query the min/max range of a flag, so parse_xss can be rewritten as
>
> const JVMTypedFlagLimit<intx>* limit =
> JVMFlagLimit::get_range_at(FLAG_MEMBER_ENUM(ThreadStackSize))->cast<intx>();
> const julong min_size = limit->min() * K;
> const julong max_size = limit->max() * K;
Ioi Lam has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains seven additional commits since the last revision:
- Merge branch 'master' of https://github.com/openjdk/jdk into 8183569-duplicated-flag-limits-parse-xss
- fixed optimized build
- @kimbarrett comments
- use macros to simplify assert_compatible_type; restore code in parse_xss so the comments make sense
- fixed typo
- use type_traits to avoid lots of boiler-plate functions
- step one
-------------
Changes:
- all: https://git.openjdk.java.net/jdk/pull/2688/files
- new: https://git.openjdk.java.net/jdk/pull/2688/files/e28c07cc..e0ad72f6
Webrevs:
- full: https://webrevs.openjdk.java.net/?repo=jdk&pr=2688&range=05
- incr: https://webrevs.openjdk.java.net/?repo=jdk&pr=2688&range=04-05
Stats: 15113 lines in 689 files changed: 8129 ins; 3848 del; 3136 mod
Patch: https://git.openjdk.java.net/jdk/pull/2688.diff
Fetch: git fetch https://git.openjdk.java.net/jdk pull/2688/head:pull/2688
PR: https://git.openjdk.java.net/jdk/pull/2688
More information about the hotspot-runtime-dev
mailing list