Mercurial > hg > graal-jvmci-8
diff src/os/solaris/vm/os_solaris.hpp @ 641:6af0a709d52b
6812587: Use auxv to determine SPARC hardware features on Solaris
Summary: A similar function to getisax(2) should be used to determine all possible instruction set extensions.
Reviewed-by: never, kvn
author | twisti |
---|---|
date | Wed, 11 Mar 2009 14:16:13 -0700 |
parents | 85f1b9537f70 |
children | c18cbe5936b8 |
line wrap: on
line diff
--- a/src/os/solaris/vm/os_solaris.hpp Tue Mar 10 08:52:16 2009 -0700 +++ b/src/os/solaris/vm/os_solaris.hpp Wed Mar 11 14:16:13 2009 -0700 @@ -1,5 +1,5 @@ /* - * Copyright 1997-2008 Sun Microsystems, Inc. All Rights Reserved. + * Copyright 1997-2009 Sun Microsystems, Inc. All Rights Reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -72,6 +72,8 @@ LGRP_VIEW_OS /* what's available to operating system */ } lgrp_view_t; + typedef uint_t (*getisax_func_t)(uint32_t* array, uint_t n); + typedef lgrp_id_t (*lgrp_home_func_t)(idtype_t idtype, id_t id); typedef lgrp_cookie_t (*lgrp_init_func_t)(lgrp_view_t view); typedef int (*lgrp_fini_func_t)(lgrp_cookie_t cookie); @@ -87,6 +89,8 @@ const uint_t info_req[], int info_count, uint64_t outdata[], uint_t validity[]); + static getisax_func_t _getisax; + static lgrp_home_func_t _lgrp_home; static lgrp_init_func_t _lgrp_init; static lgrp_fini_func_t _lgrp_fini; @@ -283,6 +287,9 @@ } static lgrp_cookie_t lgrp_cookie() { return _lgrp_cookie; } + static bool supports_getisax() { return _getisax != NULL; } + static uint_t getisax(uint32_t* array, uint_t n); + static void set_meminfo(meminfo_func_t func) { _meminfo = func; } static int meminfo (const uint64_t inaddr[], int addr_count, const uint_t info_req[], int info_count,