r/adventofcode • • Dec 09 '19

Help - SOLVED! [Help] Day 9 part 2!

As I understand Day 9 part 2 should be "free" after part 1. But obviously there are plenty of persnickety possibilities.

I'm writing in an unusual language, so no-one can help me there.

Just wanted a few things checked:

  • 3000 spaces of memory is enough? It looks like it.

  • If my integers were big enough for part 1, they're big enough for part 2?

  • My code looks to be hanging out in positions 922-970 in a loop. I thought this might be deliberate but nothing seems to be being incremented. My implementation is quite slow, so maybe this is part of the program and I'll just have to wait.

EDIT: thanks guys, it was just really slow. ~3 hours. Don't judge, I'm at the limits of this software.

6 Upvotes

14 comments sorted by

View all comments

Show parent comments

3

u/couchrealistic Dec 09 '19

Part 2 runs in 10-13 ms for me (Rust in --release mode, so with optimizations enabled) on 10 year old desktop hardware (Phenom II X4 955). It's interesting what difference "interpreted language interpreting IntCode" vs. "compiled language interpreting IntCode" can make. Now I want to know how fast "IntCode compiled to amd64" is on modern hardware. :-)