8151779: Some intrinsic flags could be replaced with one general flag

Add ControlIntrinsic switch

Reviewed-by: neliasso, phh
This commit is contained in:
Xin Liu 2020-06-23 10:40:26 -07:00
parent 6986ab256d
commit 4076ca82d2
14 changed files with 641 additions and 119 deletions

View file

@ -490,12 +490,12 @@ static void scan_flag_and_value(const char* type, const char* line, int& total_b
ResourceMark rm;
char* value = NEW_RESOURCE_ARRAY(char, strlen(line) + 1);
char* next_value = value;
if (sscanf(line, "%*[ \t]%255[_a-zA-Z0-9]%n", next_value, &bytes_read) == 1) {
if (sscanf(line, "%*[ \t]%255[_a-zA-Z0-9+\\-]%n", next_value, &bytes_read) == 1) {
total_bytes_read += bytes_read;
line += bytes_read;
next_value += bytes_read;
char* end_value = next_value-1;
while (sscanf(line, "%*[ \t]%255[_a-zA-Z0-9]%n", next_value, &bytes_read) == 1) {
while (sscanf(line, "%*[ \t]%255[_a-zA-Z0-9+\\-]%n", next_value, &bytes_read) == 1) {
total_bytes_read += bytes_read;
line += bytes_read;
*end_value = ' '; // override '\0'