Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
kr7
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
10 ms
·
31.
▲
by
kr7
10y ago
A quick test with strace on my machine shows that callocing and mallocing a 2GB buffer results in the exact same mmap system call for both. Neither use huge pages.
32.
▲
by
kr7
10y ago
> Why can't I have a malloc() that does lazy copy-on-write for large array malloc will generally do lazy copy-on-write above a certain limit; it was 128kb for glibc last time I checked. > why can't I have an error checking m
33.
▲
by
kr7
10y ago
He hates immigrants so much, he married one!
34.
▲
by
kr7
10y ago
> Cache effects are going to dominate. I see this stated frequently, but I rarely see evidence to back it up. I grabbed his code, removed the drawing function and tested it with perf [1]. (Using glibc's qsort). First test was with 1
35.
▲
by
kr7
10y ago
Or satirizing Erdogan: https://boingboing.net/2016/04/23/german-political-leader-ar... Or "hate speech", which will certainly have a chilling effect on the legitimate discussion of immigration polic
36.
▲
by
kr7
10y ago
It is illegal to take a picture of your ballot in Florida FYI: "(5) No photography is permitted in the polling room or early voting area." http://www.flsenate.gov/Laws/Statutes/2011/102.031
37.
▲
by
kr7
10y ago
Women's self-reported happiness has dropped over the last 50 years [1], so possibly add "women" too. [1] http://www.nytimes.com/2009/05/26/opinion/26douthat.html
38.
▲
by
kr7
10y ago
Here it is (warning: Perl): http://pastebin.com/MFmDzY0g It calls "objdump -d" on the binary, which is binutil's disassembler. objdump prints each instruction out in the following format: 5dc: 67
39.
▲
by
kr7
10y ago
> In fact, the average size of each instruction is almost exactly 4 bytes I was curious about this claim so I wrote a quick and dirty perl script to test it out: vmlinuz-linux = 2.71957329365681 bash = 3.95324321387071
40.
▲
by
kr7
10y ago
The pointer itself is const; not what it points to. bar -> const pointer to mutable array of ints *bar -> mutable array of ints And const pointers are dereferenced with * , not (* const), so the rule needs an exception f
41.
▲
by
kr7
10y ago
Meta-correction: AT&T owns DirecTV, not Direct TV.
42.
▲
by
kr7
10y ago
The idea to scrap it came from the Obama administration, not congress: https://www.scientificamerican.com/article/nasa-budget-const... The plan to cancel it actually included an increase in NASA's budget, so it wa
43.
▲
by
kr7
10y ago
License changes are not unheard of. Wine changed from the MIT license to LGPL without all of the developer's support.
44.
▲
by
kr7
10y ago
I hope nobody gets sick that day... (Or we could just have multi-day early voting. Like most states already do).
45.
▲
by
kr7
10y ago
There are definitely I/O side effects, but it looks like functions for mutating data structures (like set-cdr!) are intentionally unimplemented: https://github.com/aoh/owl-lisp/blob/master/scheme
46.
▲
by
kr7
10y ago
Mirror: https://i.sli.mg/MsUWXx.jpg
47.
▲
by
kr7
10y ago
Is this really necessary? https://www.instagram.com/p/BKGdQ42haF1/ EDIT: Mirror: https://i.sli.mg/MsUWXx.jpg
48.
▲
by
kr7
10y ago
Fixed-size integers and UnsafeMutablePointer are supported, so it is basically C with different syntax: https://github.com/klange/taylor/blob/master/src/main.swift
49.
▲
by
kr7
10y ago
The assembler and Makefile are x86 only. I'm not seeing support for other architectures.
50.
▲
by
kr7
10y ago
It is for running Swift code without an operating system. It could be used to write a kernel in Swift.
51.
▲
by
kr7
10y ago
As it existed in '97: https://web.archive.org/web/19970226231531/http://www.miken.... The GENERATOR tag was added in 2001-2002: https://web.archive.org/web/20020624063420/h
52.
▲
by
kr7
10y ago
I'm not sure why you're being downvoted. Store applications as byte code or source code and use a trusted JIT to generate machine code. With a system-wide garbage collector and bounds checking you would have a memory safe single a
53.
▲
by
kr7
10y ago
How many people really voted against him, though? The media thought that everyone not voting for him was voting against him. They assumed that once the field narrowed voters would rally around another candidate and defeat Trump. That neve
54.
▲
by
kr7
10y ago
Trump got the most votes of any Republican candidate in history. It probably would have been lower than 9% if Trump hadn't run.
55.
▲
by
kr7
10y ago
> a little description of what happened other than the "Cozy Bear" story would be great. Crowdstrike has published some information on what they found: https://www.crowdstrike.com/blog/bears-midst-intrusion
56.
▲
by
kr7
10y ago
std::array is not really comparable since its size is fixed at compile time. std::vector or std::list are more similar. The big advantage is creating copies. Copying a list or vector is O(n) in both time and memory, while this is O(1) in bo
57.
▲
by
kr7
10y ago
The U.S. defence budget is ~$700 billion / year and the U.S. population is ~320 million. Gutting the entire defence budget would be worth just over $2000 / year per person. Not exactly enough for UBI.
58.
▲
by
kr7
10y ago
There is no such thing as a factory with zero workers. Fewer workers, but not zero. This is not a paradigm shift; the cycle of increased efficiency destroying jobs has been going on for hundreds of years. There are so many problems that nee
59.
▲
by
kr7
10y ago
I don't think robots change anything. Robots increase efficiency of human workers, they don't replace them entirely. Netflix and Redbox are highly automated, but they still have human workers; just fewer than Blockbuster did. Robo
60.
▲
by
kr7
10y ago
From what I understand the kernel is decrypted by the firmware at boot time.
More ›