« first day (215 days earlier)      last day (742 days later) » 
00:00 - 17:0017:00 - 00:00

17:02
To do what?
calculate first 1,000 prime
ok so for code generation
likely we're going to need something like TemplatedLLVM class
which will help make LLVM functions
though VSL generator should be pretty lightweight
mainly just compiling Pointer/Int classes
everything else is STL
I think if we can parse libraries/libc/libc.vsl that is major step
17:22
@Downgoat I got 257 microseconds in C
which includes printing the numbers
of course I'm also using a really high precision timer
even if I run empty program I can't that fast
is your time code inside C?
Really though the primes aren't that great a benchmark
@Downgoat Yes, I'm using Google Benchmark
@Downgoat I mean, it's just dumb number crunching. There are some more interesting points for comparison, like strings
in The Nineteenth Byte, Dec 20 '16 at 0:56, by quartata
@Downgoat Try generaring primes or something if you want an easy test. (no builtins obviously)
17:26
Yes, an easy test
Not saying it was a good one
@quartata so like UTF8 string comparison speed?
ehh
I was thinking something that would more test the robustness of the stdlib
>_< I was thinking of opposite
@quartata wait those are unit test not benchmark?
you could check out some of the tests they use here
@Downgoat Hm?
stdlib is also significantly implemented in LLVM so probably not best benchmark
wat how is C++ faster than C
17:28
??
unless shit C
#include <benchmark.h>

#include <cstdio>
#include <cmath>

void f(void) {
  for (int i = 2; i <= 1000; i++) {
    for (int j = 2; j <= sqrt(i); j++) {
      if (i % j == 0) {
        goto next;
      }
    }

    printf("%d\n", i);
    next:;
  }
}

void f_benchmark(benchmark::State& state) {
  while (state.KeepRunning()) {
    f();
  }
}

BENCHMARK(f_benchmark);

BENCHMARK_MAIN();
I mean obviously I'm not using iostream
> apr_palloc ._.
Oh you mean on n-body
difference is pretty small
I doubt it's significant
Really there isn't any difference on any of the tests except for the regex one
And that's because the C one uses PCRE and the C++ one uses std::regex which sucks
Although a good demonstration on what I meant by "robustness of stdlib"
@Downgoat Hm?
i thought was just malloc realloc and calloc
@quartata I was thinking of just linking PCRE
17:31
apr_palloc is malloc with pool allocation
wtf is pool allocation
1
Q: Why is apr_palloc faster than malloc?

maligreeReading through The Apache Modules Book, I come across this claim in part 3.4.3: "A secondary benefit is that pool allocation is faster than malloc on most platforms!" An open question, I realize, but.. well, why?

It's not always faster
very use case dependant
At any rate I wouldn't recommend learning any C by reading the examples on Benchmark Game... they're what we call over-optimized
so I should stick with malloc in vsl?
17:35
yeah
don't worry about it
Question: is there name for a type of dictionary that is not hashmap (where time would dependent on size)
Yes, they're usually binary search trees of some form
Java would say TreeMap
but I would really just call it a dictionary and leave it up to the stdlib implementation to decide what to use for it
FWIW hashmaps can depend on size in worst cases
because normally dictionary would be like Dictionary<K: Hashable, V>
but if K is not hashable, should it need to be a different type
I guess I could do generic overload
Well it's either going to need to be hashable or comparable
OOOOOOOOOOOOGHHHHHHHHHHHHHHHHHHHHHH
I FIGURE OUT TYPE DEDUCTION
18:02
@ASCII-only if for a FunctionArgument, the Type for it ends in ?, can you set an optional paramter for the FunctionArgument node to true?
@Downgoat yeesh that was loud
18:17
hm I guess we might want to do a bottom-up tree traversal
Question: what is bottom-up tree traversal called
post-order
(probably)
actually looks like the AST GC would just work
18:52
@ASCII-only AWWW YISSS FUNCTION MANGLE WORK THIS IS GREAT NEWS
$ node test.js
ScopeItem { id: 'a(arg:A<T<U,V.B>.C,W.D<X,Y>.U>,)', original: null }
ok this is major step to compilation
wow ok
Wait, how were you able to run that prime benchmark
19:10
oh
that was benchmark for prime program parse
@ASCII-only btw made AST -> VSL code regenerator
19:22
@ASCII-only why is f(a) throwing bork at (
do we not have functions yet?
>"ah yis function mangle work" "do we not have functions yet" choose one
19:41
@quartata I mean like function call statements
@ASCII-only pls add function call, tanks
we have function declaration
@ASCII-only new vsl version have vsl -r which show transformed code.
though having deterministic mangling was a really good idae
 
1 hour later…
21:15
btw @ASCII-only is it possible to have tokenizer return comments too
For doc generator
21:35
@ASCII-only question: in first VSL for bootstrap, do we want to do implicit casting in function calls? example: if A extends B. func f(a: B) should F(a: A()) be allowed or is needing to do F(a: A() as B) for first version OK?
If we want to have in first version there are two way we can do:
1. We can go over all functions with that name and see if one has a matching signature
2. We can keep upcasting A() until we encounter a function with a matching param list
≥…¬p[=]
shit whoops ignore last message and this one
 
2 hours later…
23:54
@Downgoat halp too many pings
i woke up to 20 pings
ono
I guess start from top
@Downgoat pls no
i want language integrate docs
example?
idk actually
:( I've already did java-doc style doc comment for libvsl libc and libcurl
23:56
function thing /@ Does something. @/ (
    object: Object /@ An object. @/
) {
}
oh my
I mean in big projects descriptions can be multiple paragraphs
:| but I want DRY
00:00 - 17:0017:00 - 00:00

« first day (215 days earlier)      last day (742 days later) »