121

Re: Низькорівнева всячина

0xDADA11C7 написав:

та уникаю вживання конструкції if

так, теж спосіб до пари із "," та "?:". Правда негарно виходить із void-функціями, бо там треба приводити до int

void func(void)
{
    ...
}

if (1)
    func();
=>
1 && ((int(*)(void))func)();

і треба завжди коментувати, бо через пару місяців фіг зрозумієш що воно таке))

У мене з pelles c складності виникали коли я на ньому писав PI-код. Надмірна самостійність проявлялася при увімкненій оптимізації, і подібні хаки разом із delta-приставками компілятор просто не розумів, та коцав код. До глобальних масивів, дельту він додає вже після(O_o) використання, тому потрібно було робити додаткові __asm-милиці. Підкупає своєю простотою та невибагливістю.

Ну і ще трохи всячини - циклічний зсув, якого нам так не вистачає.

uint32_t rol(uint32_t v, uint32_t n)
{
    return n %= (sizeof(v) * 8), (v << n) | (v >> (sizeof(v) * 8 - n));
}

uint32_t ror(uint32_t v, uint32_t n)
{
    return n %= (sizeof(v) * 8), (v >> n) | (v << (sizeof(v) * 8 - n));
}
Подякували: 0xDADA11C71

122

Re: Низькорівнева всячина

На вхід подаємо хендл dll, та хеш.

get_addr(LoadLibraryA("user32.dll"), 0x572D5D8E);  //0x572D5D8E - MessageBoxA

Як, по-вашому, чи закінчиться колись теорема ескобара в плані вибору мови? З одного боку FASM має чудову макромову, яка може автоматично обчислювати геші, створювати дані довільного формату - себто вміє оперувати більш високорівневими поняттями ніж "високорівневі" мови. В якості альтернативи я розглядав мову D, але побачивши лічильники в модулях мені не схотілося з нею зв`язвувтися. Go має величезну рантайм бібліотеку, а над Rust треба довго танцювати з бубном, щоби вимкнути постійні перевірки кінця масиву. С має занадто багату спадщину, яка не дасть змінити мову.

123

Re: Низькорівнева всячина

Скільки людей - стільки і вподобань, усім не угодити єдиними синтаксичними правилами якоїсь "ідеальної мови". Мені подобається C, тому що я його непогано знаю, звик. Єдине що дратує, так це відсутність фішки яка б дозволила інкапсулювати дані (щось типу простору імен). Сі, у низькому контексті, є меншим злом, яке дозволяє на скромному (ну це так, з першого погляду) рівні задовільнити побажання кожної ідеологічної групи людей. FASM, особливо друга версія котра зараз активно розробляється, дозволяє зліпити що завгодно (як приклад, можна гарно пристосувати до вашої ВМ, або поручити створення інших екзотичних рішень типу хешування на стадії препроцессора), але в більш загальних випадках і на даній стадії, це буде створення колеса, а код треба писати прямо зараз. Звісно мати такі круті макроси, хоча й поза стандартом C, не було б зайвим. Можна комбінувати зі сриптом на python генеруючи заголовок - не подобається, нам ніхто не забороняє зробити гарніше - взяти TCC або LCC і доробити. Ідеологічно, мені близька система LLVM.

0xDADA11C7 написав:

чи закінчиться колись

Швидше створити власні інструменти відповідно до тематики праці вибравши золоту середину із декількох технологій, бо флейм про вибір мови - вічний.

Подякували: 0xDADA11C71

124

Re: Низькорівнева всячина

Таке питаннячко по асм:
в мене є код програми на FASM., і там є така штука:

filename db 'file1.txt',0  ;змінна що містить назву файлу
;........
inc byte[filename+1]     ; до цієї самої змінної додаєм 1 і виходить file2.txt

як таку штуку реалізувати в MASM/TASM?

125

Re: Низькорівнева всячина

filename db 'file1.txt',0  ;змінна що містить назву файлу
;........
inc filename[4] ; має вийти file2.txt

Той приклад на фасмі точно дає file2.txt, а не fjle1.txt?

Подякували: navchalkin1

126

Re: Низькорівнева всячина

navchalkin написав:

Таке питаннячко по асм:
в мене є код програми на FASM., і там є така штука:

filename db 'file1.txt',0  ;змінна що містить назву файлу
;........
inc byte[filename+1]     ; до цієї самої змінної додаєм 1 і виходить file2.txt

як таку штуку реалізувати в MASM/TASM?

ви б цю штуку правильно в FASM`і спочатку написали, бо поки воно з першої літери f робить літеру g. MASM/TASM відрізняється лише ключовим словом Ptr, себто замість

inc byte[filename+1]     ; до цієї самої змінної додаєм 1 і виходить gile1.txt

пишіть

inc Byte Ptr[filename+1]     ; до цієї самої змінної додаєм 1 і виходить gile1.txt
Подякували: navchalkin1

127 Востаннє редагувалося navchalkin (12.04.2016 14:02:20)

Re: Низькорівнева всячина

0xDADA11C7 написав:
inc byte[filename+1]     ; до цієї самої змінної додаєм 1 і виходить gile1.txt

пишіть

inc Byte Ptr[filename+1]     ; до цієї самої змінної додаєм 1 і виходить gile1.txt

Дуже дякую. І до речі, в FASMі виходить саме file2, a не gile2, не знаю яким чудом.
Розбираю чужу програму, якось вона працює

128

Re: Низькорівнева всячина

пробачте, має змінюватися друга літера, а не перша.

Подякували: navchalkin1

129 Востаннє редагувалося navchalkin (12.04.2016 14:10:52)

Re: Низькорівнева всячина

0xDADA11C7 написав:

пробачте, має змінюватися друга літера, а не перша.

аа, ну тоді все зрозуміло. Там назва файлу не "file1", як я написав для прикладу, а f1.
Ось тепер все ясно. До речі ваша порада працює в Emu8086. ще раз дякую:)

130

Re: Низькорівнева всячина

listing згенеруйте і самі все побачите

131

Re: Низькорівнева всячина

Множення через зсуви без прив'язки до кратності по 2n

uint32_t mul(uint32_t a, uint32_t b)
{
    uint32_t r = 0;

    for (uint32_t c = 0; c < 32; a & 1 && (r += (b << c)), c++, a >>= 1);

    return r;
}
Подякували: 0xDADA11C7, leofun012

132

Re: Низькорівнева всячина

Щоб не забути - нова технологія Windows 10 (Control Flow Guard) перешкоджає виконанню х64 коду в х86 застосунках.

Докладний опис Control Flow Guard (CFG)

Подякували: leofun01, anakin2

133 Востаннє редагувалося anakin (19.04.2016 19:16:26)

Re: Низькорівнева всячина

Стрілка Пірса та похідні від неї логічні операції.

#define nor(a, b) (~(a | b))

#define not(a      )  nor(a, a)
#define and(a, b   )  nor(nor(a, a), nor(b, b))
#define  or(a, b   )  nor(nor(a, b), nor(a, b))
#define xor(a, b   )  or(and(not(a), b), and(not(b), a))
#define jif(c, a, b)  or(and(a, c), and(not(c), b))

і суматор для тесту

uint32_t add(uint32_t a, uint32_t b)
{
    return b ? add(xor(a, b), and(a, b) << 1) : a;
}

134

Re: Низькорівнева всячина

Дякую, для морхвингу це неоціненна річ.

Подякували: anakin1

135

Re: Низькорівнева всячина

Аналогічно є штрих Шефера. Я тільки зараз оцінив, які класні штуки можна робити покрутивши математичний апарат.

Подякували: 0xDADA11C7, Юра_Максименко2

136

Re: Низькорівнева всячина

Більше правильна демонстрація суматора на стрілках: 32-бітове add (2+2)

use32

push edx
push esi
push edi
push eax
push ecx
push 2h
pop eax
or eax, 2h
not eax
push 2h
pop ecx
or ecx, 2h
not ecx
push eax
pop esi
or esi, ecx
not esi
pop ecx
pop eax
push eax
push ecx
push 2h
pop eax
or eax, 2h
not eax
push 2h
pop ecx
or ecx, 2h
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
push edi
push ecx
push esi
pop edi
or edi, esi
not edi
push esi
pop ecx
or ecx, esi
not ecx
push edi
pop eax
or eax, ecx
not eax
pop ecx
pop edi
push eax
push ecx
push esi
pop eax
or eax, esi
not eax
push esi
pop ecx
or ecx, esi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
push esi
push ecx
push eax
pop esi
or esi, eax
not esi
push edx
push ebx
push esi
pop edx
or edx, esi
not edx
push edi
pop ebx
or ebx, edi
not ebx
push edx
pop esi
or esi, ebx
not esi
pop ebx
pop edx
push edi
pop ecx
or ecx, edi
not ecx
push edx
push ebx
push ecx
pop edx
or edx, ecx
not edx
push eax
pop ebx
or ebx, eax
not ebx
push edx
pop ecx
or ecx, ebx
not ecx
pop ebx
pop edx
push edx
push ebx
push esi
pop edx
or edx, ecx
not edx
push esi
pop ebx
or ebx, ecx
not ebx
push edx
pop eax
or eax, ebx
not eax
pop ebx
pop edx
pop ecx
pop esi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edi
pop ecx
or ecx, edi
not ecx
push eax
pop edx
or edx, ecx
not edx
pop ecx
pop eax
add edx, edx
push edi
push ecx
push eax
pop edi
or edi, eax
not edi
push eax
pop ecx
or ecx, eax
not ecx
push edi
pop esi
or esi, ecx
not esi
pop ecx
pop edi
push eax
push ecx
push edx
pop eax
or eax, edx
not eax
push edx
pop ecx
or ecx, edx
not ecx
push eax
pop edi
or edi, ecx
not edi
pop ecx
pop eax
pop edi
pop esi
pop edx

використано push/pop/or/not/[add або shl]

Подякували: 0xDADA11C7, Юра_Максименко2

137

Re: Низькорівнева всячина

На макросах

macro _nor r, a, b
{
    push a
    pop r
    or r, b
    not r
}

macro _not r, a
{
    _nor r, a, a
}

macro _and r, a, b, ar, br
{
    push ar br
    _not ar, a
    _not br, b
    _nor r, ar, br
    pop br ar
}

macro _or r, a, b, ar, br
{
    push ar br
    _nor ar, a, b
    _nor br, a, b
    _nor r, ar, br
    pop br ar
}

macro _xor r, a, b, ar, br, cr, dr
{
    push ar br
    _not ar, a
    _and ar, ar, b, cr, dr

    _not br, b
    _and br, br, a, cr, dr

    _or r, ar, br, cr, dr
    pop br ar
}

macro _mov r, a, ar, br
{
    _or r, a, a, ar, br
}

І знову суматор (рекурсивний)

macro _add r, a, b, ar, br, cr, dr
{
    push cr dr

@@: test b, b
    je @f

    _mov cr, a, b, dr
    _xor r, a, b, ar, br, cr, dr
    _and cr, cr, b, a, dr
    shl cr, 1
    _mov b, cr, a, dr

    jmp @b
@@: pop dr cr
}

Це

    mov eax, 0x584d540
    mov ecx, 0x84877
    _add eax, eax, ecx, esi, edi, edx, ebx  ; eax = 058D1DB7h

Генерує наступне

    mov eax, 0x0584D540
    mov ecx, 0x00084877
    push edx
    push ebx
L_0x00402021:
    test ecx, ecx
    je  L_0x004020C4
    push ecx
    push ebx
    push eax
    pop ecx
    or ecx, eax
    not ecx
    push eax
    pop ebx
    or ebx, eax
    not ebx
    push ecx
    pop edx
    or edx, ebx
    not edx
    pop ebx
    pop ecx
    push esi
    push edi
    push eax
    pop esi
    or esi, eax
    not esi
    push edx
    push ebx
    push esi
    pop edx
    or edx, esi
    not edx
    push ecx
    pop ebx
    or ebx, ecx
    not ebx
    push edx
    pop esi
    or esi, ebx
    not esi
    pop ebx
    pop edx
    push ecx
    pop edi
    or edi, ecx
    not edi
    push edx
    push ebx
    push edi
    pop edx
    or edx, edi
    not edx
    push eax
    pop ebx
    or ebx, eax
    not ebx
    push edx
    pop edi
    or edi, ebx
    not edi
    pop ebx
    pop edx
    push edx
    push ebx
    push esi
    pop edx
    or edx, edi
    not edx
    push esi
    pop ebx
    or ebx, edi
    not ebx
    push edx
    pop eax
    or eax, ebx
    not eax
    pop ebx
    pop edx
    pop edi
    pop esi
    push eax
    push ebx
    push edx
    pop eax
    or eax, edx
    not eax
    push ecx
    pop ebx
    or ebx, ecx
    not ebx
    push eax
    pop edx
    or edx, ebx
    not edx
    pop ebx
    pop eax
    shl edx, 1 
    push eax
    push ebx
    push edx
    pop eax
    or eax, edx
    not eax
    push edx
    pop ebx
    or ebx, edx
    not ebx
    push eax
    pop ecx
    or ecx, ebx
    not ecx
    pop ebx
    pop eax
    jmp  L_0x00402021
L_0x004020C4:
    pop ebx
    pop edx

138 Востаннє редагувалося elektryk (24.04.2016 17:21:40)

Re: Низькорівнева всячина

Я бачу, що ви на асемблері  розумфєтесь. Хочу дещо "покращити" одну ДОСівську іграшку.

139

Re: Низькорівнева всячина

Створюйте окрему тему, докладно опишіть іграшку, чому вона вам цікава, що ви хочете в ній покращити та що ви можете робити для цього (відповідь "А я дивитимусь" не приймається, в зворотній розробці багато роботи і без асемблера)

140

Re: Низькорівнева всячина

0xDADA11C7 написав:

Створюйте окрему тему, докладно опишіть іграшку, чому вона вам цікава, що ви хочете в ній покращити та що ви можете робити для цього (відповідь "А я дивитимусь" не приймається, в зворотній розробці багато роботи і без асемблера)

Свою тему я створювати боюсь, бо попередні швидко опинялися на смітнику. Іграшка називається "King's Bounty-2". Вона і досі в рейтингу найкращих для ДОС. Мене вона приваблює красою алгоритму. Саме алгоритм я хочу видерти з *.ехе файлу. Для цього я хочу опанувати HIEW 6.11. А потім я планую переписати її на ДжавіСкріпт. А перед цим хочу викинути з гри всілякі москалізми.