summaryrefslogtreecommitdiff
path: root/ports/sysdeps/tile
AgeCommit message (Collapse)AuthorFilesLines
2014-01-24tile: Regenerate libm-test-ulpsChris Metcalf1-496/+1518
2014-01-01Update copyright notices with scripts/update-copyrightsAllan McRae64-64/+64
2013-09-23BZ #15754: CVE-2013-4788Carlos O'Donell1-0/+6
The pointer guard used for pointer mangling was not initialized for static applications resulting in the security feature being disabled. The pointer guard is now correctly initialized to a random value for static applications. Existing static applications need to be recompiled to take advantage of the fix. The test tst-ptrguard1-static and tst-ptrguard1 add regression coverage to ensure the pointer guards are sufficiently random and initialized to a default value.
2013-09-20Make __ffs hiddenAndreas Schwab1-0/+1
2013-08-21Fix typos.Ondřej Bílka1-1/+1
2013-07-22tile BZ #15759: Fix bug in _dl_unmapChris Metcalf1-3/+9
We returned without calling __munmap if not in the simulator. Now we call a separate sim_dlclose() function to make the control flow work correctly.
2013-07-07tile: update libm-test-ulps from scratchChris Metcalf1-129/+2795
2013-07-07tile: use soft-fp for fma() and fmaf()Chris Metcalf3-8/+99
The sfp-machine.h is based on the gcc version, but extended with required new macros by comparison with other architectures and by investigating the hardware support for FP on tile.
2013-06-30tile: switch to using <fenv.h> fallback functionsChris Metcalf6-165/+0
Now that the fallback functions match the desired semantics for tile functions, just switch to using them.
2013-06-13tile: default to little-endian in bits/endian.hChris Metcalf1-3/+1
This turns out to be helpful when doing a from-scratch cross-compile of gcc and glibc, since you can then do "make install-headers" in glibc even before you have a functioning tile gcc.
2013-06-05Remove trailing whitespace in ports.Joseph Myers1-3/+3
2013-05-29Avoid crashing in LD_DEBUG when program name is unavailableSiddhesh Poyarekar1-2/+1
Resolves: #15465 The program name may be unavailable if the user application tampers with argc and argv[]. Some parts of the dynamic linker caters for this while others don't, so this patch consolidates the check and fallback into a single macro and updates all users.
2013-05-24tile: improve detection for missing -mcmodel=large supportChris Metcalf3-4/+32
The existing test avoided passing -mcmodel=large if the compiler didn't support it. However, we need to test not just the compiler support, but also the toolchain (as and ld) support, so make the test more complete. In addition, we have to avoid using the hwN_plt() assembly operators if that support is missing, so guard the uses with #ifdef NO_PLT_PCREL. This allows us to properly build glibc with the current community binutils, which doesn't yet have the PC-relative PLT operator support. The -mcmodel=large support is in gcc 4.8, but the toolchain support won't be present in the community until binutils 2.24.
2013-05-22Don't include expected results in libm-test test names.Joseph Myers1-394/+379
2013-05-19Handle sincos with generic libm-test logic.Joseph Myers1-7/+7
2013-05-16Add #include <stdint.h> for uint[32|64]_t usage (except installed headers).Ryan S. Arnold2-0/+3
2013-01-02Update copyright notices with scripts/update-copyrights.Joseph Myers69-69/+69
2012-11-29tile: remove redundant defines of libc_fetestexcept, etc. in s_fmaf.cChris Metcalf1-4/+0
2012-11-20tile: update libm-test-ulps for new testsChris Metcalf1-0/+34
2012-11-20tile: Fix __bswap_64 return type in tile bits/byteswap.hChris Metcalf1-1/+3
2012-11-20tile: remove redundant defines of libc_fetestexcept, etc. in s_fma.cChris Metcalf1-4/+0
2012-11-06tile: use memcpy in memmove when possibleChris Metcalf1-0/+22
2012-11-06tile: use atomic op to unlock pthread_spinlock_tChris Metcalf1-0/+33
Atomic ops are issued directly from the core, rather than potentially sitting in the write buffer, so can improve the performance of other waiters. In addition, if we didn't end up pulling a copy of the cache line where the lock is into cache, by using an atomic op we don't have to acquire the cache line before we can unlock.
2012-11-06Make ieee754 fma tolerate architectures without exception support.Chris Metcalf1-7/+25
2012-11-06tile: support very large shared objectsChris Metcalf3-12/+52
With gcc 4.8 tilegx has support for -mcmodel=large, to tolerate very large shared objects. This option changes the compiler output to not include direct jump instructions, which have a range of only 2^30, i.e +/- 512MB. Instead the compiler marshalls the target PCs into registers and then uses jump- or call-to-register instructions. For glibc, the upshot is that we need to arrange for a few functions to tolerate the possibility of a large range between the PC and the target. In particular, the crti.S and start.S code needs to be able to reach from .init to the PLT, as does gmon-start.c. The elf-init.c code has the reverse problem, needing to call from libc_nonshared.a (linked at the end of shared objects) back to the _init section at the beginning. No other functions in *_nonshared.a need to be built this way, as they only call the PLT (or potentially each other), but all of that code is linked at the very end of the shared object. We don't build the standard -static archives with this option as the performance cost is high enough and the use case is rare enough that it doesn't seem worthwhile. Instead, we would encourage developers who need the -static model with huge executables to build a private copy of glibc and configure it with -mcmodel=large. Note that libc.so et al don't need any changes; the only changes are for code that is statically linked into user code built with -mcmodel=large. For the assembly code, I just rewrote it so that it unconditionally uses the large model. To be able to pass -mcmodel=large to csu/elf-init.c and csu/gmon-start.c, I need to check to see if the compiler supports that flag, since gcc 4.7 doesn't; I added the support by creating a small Makefile fragment that just runs the compiler to check.
2012-11-06tile: improve simulator notification for relative paths in dlopenChris Metcalf1-14/+89
Normally, the simulator is notified of absolute pathnames by the _dl_load_hook hook. However, when a relative pathname is used, the simulator may not know that the relative path matches a path that it could figure out in the file system that it has access to. Instead we provide a simplified version of the realpath function so we can pass a plausible absolute pathname to the simulator. Since we're now doing more work at object load time, we also add a guard so we do no work at all if we're not running on the simulator.
2012-11-06Optimize tile (mostly tilegx) memcpy and memmove performance.Chris Metcalf3-67/+609
- Override <memcopy.h> so we use full 8-byte word copies on tilegx32 for memmove, then use op_t in memcpy instead of the previous locally-defined word_t just to avoid proliferating identical types. - Fix bug in memcpy prefetch that caused us to never prefetch past the first cache line. - Optimize misaligned memcpy by inlining _wordcopy_fwd_dest_aligned instead of just doing a dumb word-at-a-time copy. - Make memcpy safe for forward copies by doing all the loads from a given cache line prior to doing a wh64 (cache line zero-fill) on the destination. Remove now-redundant src == dst check. - Copy and optimize the generic wordcopy.c routines to use the tile "double align" instruction instead of the MERGE macro; to avoid offset addressing mode (which tile doesn't have) by rewriting the pointer math to load and store with a zero index; and to use post-increment addresses in the inner loops to improve scheduling.
2012-11-03Make fenv.h FE_* macros usable in #if (bug 3439).Joseph Myers1-3/+4
2012-11-03tile: Account for new tests (missed test-double changes)Chris Metcalf1-0/+16
2012-10-30Invoke DL_AFTER_LOAD if definedChris Metcalf2-5/+3
This hook is useful for any arch-specific functionality that should be done on loaded objects. For the tile architecture, the hook is already provided (though we switch to using the new macro name with this commit) and implements a simulator notifier so that the simulator can load Elf symbols to match the object and generate better error messages for PC's. Also, remove a spurious definition of DL_UNMAP in dl-runtime.c
2012-10-30tile: update libm-test-ulps for new testsChris Metcalf1-2/+50
2012-09-24tile: fix two comments that said "tile" to properly say "tilepro"Chris Metcalf1-2/+2
2012-09-17tile: update libm-test-ulps for new testsChris Metcalf1-2/+91
2012-09-06tile: BZ#14237: fix __tls_get_addr bug initializing new modulesChris Metcalf1-0/+2
We were missing a check for TLS_DTV_UNALLOCATED; if set, we need to go to the slow path.
2012-08-04tile: fix typo in ASM_TYPE_DIRECTIVE fixChris Metcalf1-1/+1
2012-08-02tile: Get rid of ASM_TYPE_DIRECTIVEChris Metcalf1-3/+2
2012-07-17tile: update libm test ULPsChris Metcalf1-0/+116
2012-07-10tile: Convert ASM_GLOBAL_DIRECTIVE to .globlChris Metcalf1-1/+1
2012-07-01Move all files into ports/ subdirectory in preparation for merge with glibcJoseph Myers87-0/+7010