| title |
|---|
Rich errors messages in GHC |
See the proposal.
| #!/usr/bin/env python3 | |
| """ | |
| Compute link order | |
| """ | |
| import sys | |
| from pathlib import Path | |
| import typing | |
| from typing import Set, NamedTuple |
| ulimit -n 32000 | |
| _build/stage1/bin/ghc -O -threaded -rtsopts EchoServer.hs -debug | |
| ./EchoServer +RTS -N4 -s -DS -RTS & | |
| echo 'GET http://localhost:3000/' | nix run nixpkgs.vegeta -c vegeta attack -rate 4000 -body Vagrantfile >out | |
| kill %1 | |
| nix run nixpkgs.vegeta -c vegeta report < out |
| let | |
| haskellNixSrc = builtins.fetchTarball https://github.com/input-output-hk/haskell.nix/archive/a823ba4b7126d11ca272ef70b842b0ea5523fcfd.tar.gz; | |
| haskellNix = import haskellNixSrc {}; | |
| nixpkgsSrc = haskellNix.sources.nixpkgs-2003; | |
| nixpkgsArgs = haskellNix.nixpkgsArgs; | |
| in | |
| { pkgs ? (import nixpkgsSrc nixpkgsArgs).pkgsCross.aarch64-multiplatform-musl | |
| }: | |
| let | |
| hspkgs = pkgs.haskell-nix.stackProject { |
| diff --git a/runstdtest/runstdtest.prl b/runstdtest/runstdtest.prl | |
| index 4ac632f..fb12099 100644 | |
| --- a/runstdtest/runstdtest.prl | |
| +++ b/runstdtest/runstdtest.prl | |
| @@ -209,7 +209,7 @@ if ($PostScript ne '') { | |
| # OK, so we're gonna do the normal thing... | |
| if ($Cachegrind eq 'yes') { | |
| - $CachegrindPrefix = "valgrind --tool=cachegrind --log-fd=9 9>$CachegrindStats"; | |
| + $CachegrindPrefix = "valgrind --tool=cachegrind --dsymutil=no --log-fd=9 9>$CachegrindStats"; |
| #include <stdint.h> | |
| #include <fenv.h> | |
| float hs_word2float32_old(uint64_t x) { | |
| return (float)x; | |
| } | |
| float hs_word2float32_new(uint64_t x) { | |
| int r = fegetround(); | |
| fesetround(FE_TOWARDZERO); |
| #include <string.h> | |
| #include <stdlib.h> | |
| #include <stdio.h> | |
| /* | |
| * See https://gitlab.haskell.org/ghc/ghc/wikis/commentary/compiler/symbol-names | |
| */ | |
| /* | |
| * Returns number of characters decoded including NULL-terminator or zero if |
| CPU time, elapsed | |
| Productivity Mutator GC | |
| CPU elapsed CPU elapsed | |
| ------------- ----- -------- ----- -------- | |
| -j1 -A1M 83% 33.5 43.9 6.8 6.8 | |
| -j4 -A1M 56% 48.4 24.4 38.8 10.9 | |
| -j4 -A16M 60% 49.3 25.0 33.2 9.3 | |
| -j4 -A64M 80% 49.7 25.4 11.9 3.5 | |
| -j4 -A16M -qn2 77% 49.0 24.6 14.7 7.5 |
| 0.63 4.02 | |
| 0.64 3.98 | |
| 0.62 3.93 | |
| 0.57 3.94 | |
| 0.63 3.90 | |
| 0.58 3.88 | |
| 0.62 3.87 | |
| 0.68 4.09 | |
| 0.62 4.09 | |
| 0.61 4.09 |
| title |
|---|
Rich errors messages in GHC |
See the proposal.
| data StackField b = PointerField b | |
| | WordField !Word | |
| data StackFrame b = StackFrame { infoTable :: StgInfoTable | |
| , fields :: [StackField b] | |
| } | |
| data GenClosure b = ... | |
| | StackClosure [StackFrame b] |