Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7068035
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T05:16:29+00:00 2026-05-28T05:16:29+00:00

Is there a tutorial somewhere which explains all the intricacies of boolean logic operations

  • 0

Is there a tutorial somewhere which explains all the intricacies of boolean logic operations which are possible in assembly language. For example, I have no idea what the following assembly code block does:

mov     [ebp-8h], 31982853h
mov     eax, [ebp+Ch]
shl     eax, 8
mov     ecx, [ebp+Ch]
shr     ecx, 8
or      eax, ecx

I understand what the shl, shr and or instructions do but have no idea about their combined result.
Can anybody direct me to a tutorial which thoroughly explains boolean logic operations in assembly?

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T05:16:30+00:00Added an answer on May 28, 2026 at 5:16 am

    Annotated code:

    mov     eax, [ebp+Ch]   ; grab our 32-bit value
    shl     eax, 8          ; shift it left 8 bits, so the top 8 bits are shifted out 
                            ; and the bottom 8 bits are filled w/ 0
    mov     ecx, [ebp+Ch]   ; grab our 32-bit value again
    shr     ecx, 8          ; shift this copy right 8 bits, so the bottom 8 bits are 
                            ; shifted out and the top 8 bits are filled w/ 0
    or      eax, ecx        ; perform A = A or C for each set of same-aligned bits in
                            ; EAX (A) and ECX (C)
    

    So if the original value was ABCD (each letter being an 8-bit byte), then before the or is performed, EAX would have BCD0 and ECX would have 0ABC.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there a tutorial somewhere which shows how to use spring framework with maven
Is there a simple tutorial for this somewhere? Ideally I'd like to have a
Is there a good tutorial or does anyone have experience with setting this up
Is there a good debugging tutorial for VS 2008 (C#, more precisely)? I have
I'm pretty sure that I read somewhere that it's possible, but there are a
Is there, somewhere a tutorial on how to make an eclipse plugin. need it
I was wondering if there was a tutorial somewhere on how to create a
Is there a tutorial on how to deploy Pylons with Nginx? I've been able
if yes, is there a tutorial available for creating an android app using the
Is there a good tutorial on using regular expressions, especially with grep ? I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.