Commit a0b5bb6e authored by Andres Freund's avatar Andres Freund

Improve comment spelling and style in llvmjit_deform.c.

Author: Justin Pryzby
Discussion:
    https://postgr.es/m/20190408141828.GE10080@telsasoft.com
    https://postgr.es/m/20181127184133.GM10913@telsasoft.com
parent 3a48005b
...@@ -386,7 +386,7 @@ slot_compile_deform(LLVMJitContext *context, TupleDesc desc, ...@@ -386,7 +386,7 @@ slot_compile_deform(LLVMJitContext *context, TupleDesc desc,
/* /*
* If this is the first attribute, slot->tts_nvalid was 0. Therefore * If this is the first attribute, slot->tts_nvalid was 0. Therefore
* reset offset to 0 to, it be from a previous execution. * also reset offset to 0, it may be from a previous execution.
*/ */
if (attnum == 0) if (attnum == 0)
{ {
...@@ -416,7 +416,7 @@ slot_compile_deform(LLVMJitContext *context, TupleDesc desc, ...@@ -416,7 +416,7 @@ slot_compile_deform(LLVMJitContext *context, TupleDesc desc,
/* /*
* Check for nulls if necessary. No need to take missing attributes * Check for nulls if necessary. No need to take missing attributes
* into account, because in case they're present the heaptuple's natts * into account, because if they're present the heaptuple's natts
* would have indicated that a slot_getmissingattrs() is needed. * would have indicated that a slot_getmissingattrs() is needed.
*/ */
if (!att->attnotnull) if (!att->attnotnull)
...@@ -503,13 +503,13 @@ slot_compile_deform(LLVMJitContext *context, TupleDesc desc, ...@@ -503,13 +503,13 @@ slot_compile_deform(LLVMJitContext *context, TupleDesc desc,
(known_alignment < 0 || known_alignment != TYPEALIGN(alignto, known_alignment))) (known_alignment < 0 || known_alignment != TYPEALIGN(alignto, known_alignment)))
{ {
/* /*
* When accessing a varlena field we have to "peek" to see if we * When accessing a varlena field, we have to "peek" to see if we
* are looking at a pad byte or the first byte of a 1-byte-header * are looking at a pad byte or the first byte of a 1-byte-header
* datum. A zero byte must be either a pad byte, or the first * datum. A zero byte must be either a pad byte, or the first
* byte of a correctly aligned 4-byte length word; in either case * byte of a correctly aligned 4-byte length word; in either case,
* we can align safely. A non-zero byte must be either a 1-byte * we can align safely. A non-zero byte must be either a 1-byte
* length word, or the first byte of a correctly aligned 4-byte * length word, or the first byte of a correctly aligned 4-byte
* length word; in either case we need not align. * length word; in either case, we need not align.
*/ */
if (att->attlen == -1) if (att->attlen == -1)
{ {
...@@ -603,8 +603,8 @@ slot_compile_deform(LLVMJitContext *context, TupleDesc desc, ...@@ -603,8 +603,8 @@ slot_compile_deform(LLVMJitContext *context, TupleDesc desc,
else if (att->attnotnull && attguaranteedalign && known_alignment >= 0) else if (att->attnotnull && attguaranteedalign && known_alignment >= 0)
{ {
/* /*
* If the offset to the column was previously known a NOT NULL & * If the offset to the column was previously known, a NOT NULL &
* fixed width column guarantees that alignment is just the * fixed-width column guarantees that alignment is just the
* previous alignment plus column width. * previous alignment plus column width.
*/ */
Assert(att->attlen > 0); Assert(att->attlen > 0);
...@@ -645,8 +645,8 @@ slot_compile_deform(LLVMJitContext *context, TupleDesc desc, ...@@ -645,8 +645,8 @@ slot_compile_deform(LLVMJitContext *context, TupleDesc desc,
LLVMBuildGEP(b, v_tts_nulls, &l_attno, 1, "")); LLVMBuildGEP(b, v_tts_nulls, &l_attno, 1, ""));
/* /*
* Store datum. For byval datums copy the value, extend to Datum's * Store datum. For byval: datums copy the value, extend to Datum's
* width, and store. For byref types, store pointer to data. * width, and store. For byref types: store pointer to data.
*/ */
if (att->attbyval) if (att->attbyval)
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment