Parentheses generally mean to dereference. 0x8(%rsp) means "get the location on the stack that is 8 bytes away from the stack pointer %rsp, and then take the value at that address."
It moves 0x131 into %eax, and then compares it to the data at that location. cmp sets the eflags
register depending on that comparison (like the Zero Flag if the operands were equal, etc.)
To see what is at the address using GDB, type
(gdb) x/1dw 0x8(%esp)
This command 'x' examines memory.
1 means examine 1 of whatever unit is specified.
"d" means output in decimal notation (as opposed to hex). I don't know what type of data you are making a comparison to, so you might use "c" to get a char, or "x" to get a hex, or "s" for a string, or whatever.
"w" provides the unit, in this case a word, which is 4 bytes.
So this command looks at 4 bytes at the given address, 0x8(%rsp), and prints whatever is there in decimal format.
To learn more about using GDB to see how your memory is changing, see this document.