comparison gcc/common/config/bfin/bfin-common.c @ 145:1830386684a0

gcc-9.2.0
author anatofuz
date Thu, 13 Feb 2020 11:34:05 +0900
parents 84e7813d76e9
children
comparison
equal deleted inserted replaced
131:84e7813d76e9 145:1830386684a0
1 /* Common hooks for Blackfin. 1 /* Common hooks for Blackfin.
2 Copyright (C) 2005-2018 Free Software Foundation, Inc. 2 Copyright (C) 2005-2020 Free Software Foundation, Inc.
3 3
4 This file is part of GCC. 4 This file is part of GCC.
5 5
6 GCC is free software; you can redistribute it and/or modify it 6 GCC is free software; you can redistribute it and/or modify it
7 under the terms of the GNU General Public License as published 7 under the terms of the GNU General Public License as published
299 299
300 switch (code) 300 switch (code)
301 { 301 {
302 case OPT_mshared_library_id_: 302 case OPT_mshared_library_id_:
303 if (value > MAX_LIBRARY_ID) 303 if (value > MAX_LIBRARY_ID)
304 error_at (loc, "-mshared-library-id=%s is not between 0 and %d", 304 error_at (loc, "%<-mshared-library-id=%s%> is not between 0 and %d",
305 arg, MAX_LIBRARY_ID); 305 arg, MAX_LIBRARY_ID);
306 return true; 306 return true;
307 307
308 case OPT_mcpu_: 308 case OPT_mcpu_:
309 { 309 {
318 i++; 318 i++;
319 } 319 }
320 320
321 if (p == NULL) 321 if (p == NULL)
322 { 322 {
323 error_at (loc, "-mcpu=%s is not valid", arg); 323 error_at (loc, "%<-mcpu=%s%> is not valid", arg);
324 return false; 324 return false;
325 } 325 }
326 326
327 opts->x_bfin_cpu_type = bfin_cpus[i].type; 327 opts->x_bfin_cpu_type = bfin_cpus[i].type;
328 328
354 if (sscanf (q, "-%u.%u%n", &si_major, &si_minor, &n) != 2 354 if (sscanf (q, "-%u.%u%n", &si_major, &si_minor, &n) != 2
355 || n != rev_len 355 || n != rev_len
356 || si_major > 0xff || si_minor > 0xff) 356 || si_major > 0xff || si_minor > 0xff)
357 { 357 {
358 invalid_silicon_revision: 358 invalid_silicon_revision:
359 error_at (loc, "-mcpu=%s has invalid silicon revision", arg); 359 error_at (loc, "%<-mcpu=%s%> has invalid silicon revision",
360 arg);
360 return false; 361 return false;
361 } 362 }
362 363
363 opts->x_bfin_si_revision = (si_major << 8) | si_minor; 364 opts->x_bfin_si_revision = (si_major << 8) | si_minor;
364 365