piglit test suite contains smaller OpenCL tests (basically
unit tests) which are useful to get working.

Get the upstream repo to examples/piglit directory: 

  git clone git://anongit.freedesktop.org/piglit

Reconfigure pocl. Piglit should now appear in enabled testsuite list at 
the end of the configure output.

Build the piglit test framework by running make in pocl top source directory

  make check TESTSUITEFLAGS="-k piglit"

Running the piglit tests separately: 

Setup ocl-icd to use the build tree pocl

  export OCL_ICD_VENDORS=LOCATION_TO_POCL_ROOT/ocl-vendors

Run the OCL test suite in piglit source directory.

  ./piglit-run.py tests/all_cl.tests results/all

Produce a summary HTML page of the results

  ./piglit-summary-html.py summary/pocl results/all/main

Now under summary/pocl there should be index.html etc. which
can be used to browse the test results and logs.

If you do something affecting piglit test results (fix something to make a 
test pass) then you should make new reference file by 
running:
piglit/piglit-run.py -v piglit/tests/cl.tests results/all 2>&1 | grep "pass " | LC_ALL=C sort -o sorted_ref


