StrategyNumber
 amtranslatecmptype (CompareType cmptype, Oid opfamily, Oid opcintype);
 </programlisting>
-   These functions, if implemented, will be called by the planer and executor
+   These functions, if implemented, will be called by the planner and executor
    to convert between fixed <type>CompareType</type> values and the specific
    strategy numbers used by the access method.  These functions can be
    implemented by access methods that implement functionality similar to the
 
        return NULL;
 
    /*
-    * The index attnum points directly to a relation attnum, then it's no an
+    * The index attnum points directly to a relation attnum, then it's not an
     * expression attribute.
     */
    if (rel->rd_index->indkey.values[attnum - 1] != 0)
 
 
 /*
  * Helper function to release lock, shared between LWLockRelease() and
- * LWLockeleaseDisowned().
+ * LWLockReleaseDisowned().
  */
 static void
 LWLockReleaseInternal(LWLock *lock, LWLockMode mode)
 
 /*
  * Returns statistics of a backend by pid.
  *
- * This routine includes sanity checks to ensire that the backend exists and
+ * This routine includes sanity checks to ensure that the backend exists and
  * is running.  "bktype" can be optionally defined to return the BackendType
  * of the backend whose statistics are returned.
  */
 
 
    /* verify optimization stated above stays valid */
    StaticAssertStmt(MAX_BACKENDS_BITS <= 23,
-                    "MAX_BACKEND_BITS is too big for inval.c");
+                    "MAX_BACKENDS_BITS is too big for inval.c");
 
    msg.sm.id = SHAREDINVALSMGR_ID;
    msg.sm.backend_hi = rlocator.backend >> 16;
 
             'TESTLOGDIR': os.path.join(testdir, 'log')}
 
 
-# The configuration time value of PG_TEST_EXTRA is supplied via arguement
+# The configuration time value of PG_TEST_EXTRA is supplied via argument
 # --pg-test-extra. But it can be overridden by environment variable
 # PG_TEST_EXTRA at the time of running a test. Hence use value from arguments
 # only if PG_TEST_EXTRA is not set in the test environment, which already