Блог пользователя MikeMirzayanov

Автор MikeMirzayanov, 3 года назад, По-английски

Hey! I'm happy to report that Pypy3 is supported. Please test that it works as expected. Thanks!

P.S. I remember about GCC 11, it is in the progress. See you soon.

  • Проголосовать: нравится
  • +361
  • Проголосовать: не нравится

»
3 года назад, # |
  Проголосовать: нравится +31 Проголосовать: не нравится

Wow! Now using python will be more impressive.

»
3 года назад, # |
  Проголосовать: нравится +15 Проголосовать: не нравится

Thanks MikeMirzayanov for sharing the good news about the coming support of GCC 11.

»
3 года назад, # |
  Проголосовать: нравится +113 Проголосовать: не нравится

Quick test:

MOD = 10 ** 9 + 7
N = 10 ** 4
total = 0
for x in range(10 ** 9 - N, 10 ** 9):
    for y in range(10 ** 9 - N, 10 ** 9):
        total += x * y % MOD
        total %= MOD
print(total)

Before: Used: 7190 ms, 3580 KB

With 64 bit: Used: 467 ms, 2372 KB

Yay!

»
3 года назад, # |
  Проголосовать: нравится +21 Проголосовать: не нравится

"You cannot [up]vote twice. You have already [up]voted for this topic before."

Looks good on the issue of sorting gratuitously large ints as seen in 1539/C - Stable Groups and 1574/C - Slay the Dragon.

I/O looks about the same or better but I really should avoid using 1543/D1 - RPD and Rap Sheet (Easy Version) for anything, really (interactive, adaptive-of-adaptive grader which only guarantees that there'll be a lot of I/O, but not a consistent amount). Side thought: any chance on increasing the input limit of custom invocation to match the more ridiculous problems out there?

Untested/todo/esoterica: find good parameters for thread-parameter-stack-space kludge for the sake of extremely deep recursion...? Been a while since I tried, but I remember it being passable on python but memory-splosive on pypy.

Haven't run into as far as I can tell: tuples bad, somehow?

Thanks for all you do... not sure what the endgame is re: libraries, but I'll hold off on the 'numba precompiler when?' talk for now :P

  • »
    »
    3 года назад, # ^ |
      Проголосовать: нравится +4 Проголосовать: не нравится

    Memory usage is different, but that's expected. Unfortunately, I suspect the class of problems I typically solve in-contest flies below running into such issues...? fwiw my horrid upsolve/AC on 1574D - Strongest Build got nudged into MLE by switching to pypy3-64.

    Fingers crossed for consistently thorough (max) pretests, I guess...

»
3 года назад, # |
  Проголосовать: нравится +5 Проголосовать: не нравится

Yay !

I really like that !

»
3 года назад, # |
  Проголосовать: нравится -6 Проголосовать: не нравится

That is great! Although I haven't learned Python yet, I heard that PyPy 3 will bring a better experience to Python programmers. Happy for them!

Also, looking forward to the release of GCC 11!

»
3 года назад, # |
  Проголосовать: нравится +18 Проголосовать: не нравится

This is great! Seems like solutions dealing with int-64s run a lot faster! Now problems like 1466E - Apollo versus Pan can be solved in PyPy3 without splitting a bigger number into 2 integers (int-32).

»
3 года назад, # |
  Проголосовать: нравится +10 Проголосовать: не нравится

Found out about this by (pleasant) surprise. Same Python code for 710E DP problem was TLE on both Python 3 & PyPy 3 but AC on PyPy3-64

»
3 года назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

When will this be available in Polygon?

»
3 года назад, # |
  Проголосовать: нравится +4 Проголосовать: не нравится

Thanks MikeMirzayanov for the update, much appreciated!

I noticed some weird behaviors while using pypy3-64 during the last Codeforces Round #763 (Div. 2):

Problem: A. Robot Cleaner

Issue:

Seems to me more likely a bug rather than performance issue? Would appreciate if someone from the CF team could investigate for the sake of future contests.