[polly] r215871 - Added arcanist linters and cleaned errors and warnings
Johannes Doerfert
doerfert at cs.uni-saarland.de
Sun Aug 17 17:40:13 PDT 2014
Author: jdoerfert
Date: Sun Aug 17 19:40:13 2014
New Revision: 215871
URL: http://llvm.org/viewvc/llvm-project?rev=215871&view=rev
Log:
Added arcanist linters and cleaned errors and warnings
Arcanist (arc) will now always run linters before uploading any new
commit to Phabricator. All errors/warnings (or their absence) will be
shown in the web interface together with a explanation by the commiter
(arcanist will ask the commiter if the build was not clean).
The linters include:
- clang-format
- spelling check
- permissions check (aka. chmod)
- filename check
- merge conflict marker check
Note, that their scope is sometimes limited (see .arclint for
details).
This commit also fixes all errors and warnings these linters reported,
namely:
- spelling mistakes and typos
- executable permissions for various text files
Differential Revision: http://reviews.llvm.org/D4916
Added:
polly/trunk/.arclint
Modified:
polly/trunk/.arcconfig
polly/trunk/CMakeLists.txt
polly/trunk/autoconf/configure.ac
polly/trunk/autoconf/configure.bak
polly/trunk/lib/Analysis/ScopInfo.cpp
polly/trunk/lib/JSON/include/json/value.h
polly/trunk/lib/JSON/include/json/writer.h
polly/trunk/lib/Transform/CodePreparation.cpp
polly/trunk/test/Cloog/ambigous_schedule.ll
polly/trunk/utils/check_format.sh
polly/trunk/www/video-js/video.js
Modified: polly/trunk/.arcconfig
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/.arcconfig?rev=215871&r1=215870&r2=215871&view=diff
==============================================================================
--- polly/trunk/.arcconfig (original)
+++ polly/trunk/.arcconfig Sun Aug 17 19:40:13 2014
@@ -1,4 +1,6 @@
{
"project_id" : "polly",
- "conduit_uri" : "http://reviews.llvm.org/"
+ "conduit_uri" : "http://reviews.llvm.org/",
+ "linter.scriptandregex.script": "sh -c './utils/check_format.sh \"$0\" 2> /dev/null || true'",
+ "linter.scriptandregex.regex": "/^(OK:(?P<ignore>.+)|Error:) (?P<message>.+)$/m"
}
Added: polly/trunk/.arclint
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/.arclint?rev=215871&view=auto
==============================================================================
--- polly/trunk/.arclint (added)
+++ polly/trunk/.arclint Sun Aug 17 19:40:13 2014
@@ -0,0 +1,23 @@
+{
+ "linters": {
+ "format": {
+ "include": "(include/polly/.+\\.h$|lib/.+\\.cpp$)",
+ "exclude": "(lib/JSON/.*)",
+ "type": "script-and-regex"
+ },
+ "chmod": {
+ "type": "chmod"
+ },
+ "filename": {
+ "exclude": "(www/experiments/.+|.*\\.jscop.*)",
+ "type": "filename"
+ },
+ "merge-conflict": {
+ "type": "merge-conflict"
+ },
+ "spelling": {
+ "exclude": "(configure|autoconf/.*)",
+ "type": "spelling"
+ }
+ }
+}
Modified: polly/trunk/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/CMakeLists.txt?rev=215871&r1=215870&r2=215871&view=diff
==============================================================================
--- polly/trunk/CMakeLists.txt (original)
+++ polly/trunk/CMakeLists.txt Sun Aug 17 19:40:13 2014
@@ -12,7 +12,7 @@ if (NOT DEFINED LLVM_MAIN_SRC_DIR)
#FileCheck is not install by default, warn the user to Copy FileCheck
if( NOT EXISTS ${LLVM_INSTALL_ROOT}/bin/FileCheck
OR NOT EXISTS ${LLVM_INSTALL_ROOT}/bin/not)
- message(WARNING "FileCheck or not are requred by running regress tests, "
+ message(WARNING "FileCheck or not are required by running regress tests, "
"but they are not installed! Please copy it to "
"${LLVM_INSTALL_ROOT}/bin.")
endif(NOT EXISTS ${LLVM_INSTALL_ROOT}/bin/FileCheck
Modified: polly/trunk/autoconf/configure.ac
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/autoconf/configure.ac?rev=215871&r1=215870&r2=215871&view=diff
==============================================================================
--- polly/trunk/autoconf/configure.ac (original)
+++ polly/trunk/autoconf/configure.ac Sun Aug 17 19:40:13 2014
@@ -11,7 +11,7 @@ dnl Tell autoconf that this is an LLVM p
dnl This provides the --with-llvmsrc and --with-llvmobj options
LLVM_CONFIG_PROJECT($LLVM_SRC_ROOT,$LLVM_OBJ_ROOT)
-dnl Tell autoconf that the auxilliary files are actually located in
+dnl Tell autoconf that the auxiliary files are actually located in
dnl the LLVM autoconf directory, not here.
AC_CONFIG_AUX_DIR($LLVM_SRC/autoconf)
Modified: polly/trunk/autoconf/configure.bak
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/autoconf/configure.bak?rev=215871&r1=215870&r2=215871&view=diff
==============================================================================
--- polly/trunk/autoconf/configure.bak (original)
+++ polly/trunk/autoconf/configure.bak Sun Aug 17 19:40:13 2014
@@ -6,7 +6,7 @@ AC_INIT([Polly],[0.01],[etherzhhb at gmail.
dnl Identify where LLVM source tree is
LLVM_SRC_ROOT="../.."
LLVM_OBJ_ROOT="../.."
-dnl Tell autoconf that the auxilliary files are actually located in
+dnl Tell autoconf that the auxiliary files are actually located in
dnl the LLVM autoconf directory, not here.
AC_CONFIG_AUX_DIR($LLVM_SRC_ROOT/autoconf)
Modified: polly/trunk/lib/Analysis/ScopInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/Analysis/ScopInfo.cpp?rev=215871&r1=215870&r2=215871&view=diff
==============================================================================
--- polly/trunk/lib/Analysis/ScopInfo.cpp (original)
+++ polly/trunk/lib/Analysis/ScopInfo.cpp Sun Aug 17 19:40:13 2014
@@ -55,7 +55,7 @@ using namespace polly;
STATISTIC(ScopFound, "Number of valid Scops");
STATISTIC(RichScopFound, "Number of Scops containing a loop");
-// Multiplicative reductions can be disabled seperately as these kind of
+// Multiplicative reductions can be disabled separately as these kind of
// operations can overflow easily. Additive reductions and bit operations
// are in contrast pretty stable.
static cl::opt<bool> DisableMultiplicativeReductions(
Modified: polly/trunk/lib/JSON/include/json/value.h
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/JSON/include/json/value.h?rev=215871&r1=215870&r2=215871&view=diff
==============================================================================
--- polly/trunk/lib/JSON/include/json/value.h (original)
+++ polly/trunk/lib/JSON/include/json/value.h Sun Aug 17 19:40:13 2014
@@ -617,7 +617,7 @@ namespace Json {
/** \brief A linked page based hash-table implementation used internally by Value.
* \internal ValueInternalMap is a tradional bucket based hash-table, with a linked
- * list in each bucket to handle collision. There is an addional twist in that
+ * list in each bucket to handle collision. There is an additional twist in that
* each node of the collision linked list is a page containing a fixed amount of
* value. This provides a better compromise between memory usage and speed.
*
Modified: polly/trunk/lib/JSON/include/json/writer.h
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/JSON/include/json/writer.h?rev=215871&r1=215870&r2=215871&view=diff
==============================================================================
--- polly/trunk/lib/JSON/include/json/writer.h (original)
+++ polly/trunk/lib/JSON/include/json/writer.h Sun Aug 17 19:40:13 2014
@@ -23,7 +23,7 @@ namespace Json {
/** \brief Outputs a Value in <a HREF="http://www.json.org">JSON</a> format without formatting (not human friendly).
*
* The JSON document is written in a single line. It is not intended for 'human' consumption,
- * but may be usefull to support feature such as RPC where bandwith is limited.
+ * but may be useful to support feature such as RPC where bandwidth is limited.
* \sa Reader, Value
*/
class JSON_API FastWriter : public Writer
Modified: polly/trunk/lib/Transform/CodePreparation.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/Transform/CodePreparation.cpp?rev=215871&r1=215870&r2=215871&view=diff
==============================================================================
--- polly/trunk/lib/Transform/CodePreparation.cpp (original)
+++ polly/trunk/lib/Transform/CodePreparation.cpp Sun Aug 17 19:40:13 2014
@@ -18,7 +18,7 @@
// variables. Such variables are generated before scop detection and
// also before the code preparation pass. All PHI nodes that are not canonical
// induction variables are not supported by the indvars based code generation
-// and are consequently translated into explict memory accesses.
+// and are consequently translated into explicit memory accesses.
//
// - scev based code generation:
//
Modified: polly/trunk/test/Cloog/ambigous_schedule.ll
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/test/Cloog/ambigous_schedule.ll?rev=215871&r1=215870&r2=215871&view=diff
==============================================================================
--- polly/trunk/test/Cloog/ambigous_schedule.ll (original)
+++ polly/trunk/test/Cloog/ambigous_schedule.ll Sun Aug 17 19:40:13 2014
@@ -91,7 +91,7 @@ for.end30:
; CHECK: }
; CHECK: }
-; This check makes sure CLooG stops splitting for ambigious schedules as
+; This check makes sure CLooG stops splitting for ambiguous schedules as
; they may be generated by the isl/PoCC/Pluto schedule optimizers.
;
; Previously we created such code:
Modified: polly/trunk/utils/check_format.sh
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/utils/check_format.sh?rev=215871&r1=215870&r2=215871&view=diff
==============================================================================
--- polly/trunk/utils/check_format.sh (original)
+++ polly/trunk/utils/check_format.sh Sun Aug 17 19:40:13 2014
@@ -14,7 +14,7 @@ OK=0
for ARG in "$@"
do
- ${CLANG_FORMAT} $ARG | diff -u $ARG -
+ ${CLANG_FORMAT} -style=llvm $ARG | diff -u $ARG - >&2
if [[ $? -eq 1 ]]; then
OK=1
Modified: polly/trunk/www/video-js/video.js
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/www/video-js/video.js?rev=215871&r1=215870&r2=215871&view=diff
==============================================================================
--- polly/trunk/www/video-js/video.js (original)
+++ polly/trunk/www/video-js/video.js Sun Aug 17 19:40:13 2014
@@ -39,7 +39,7 @@ var VideoJS = JRClass.extend({
this.video = element;
}
// Store reference to player on the video element.
- // So you can acess the player later: document.getElementById("video_id").player.play();
+ // So you can access the player later: document.getElementById("video_id").player.play();
this.video.player = this;
this.values = {}; // Cache video values.
this.elements = {}; // Store refs to controls elements.
@@ -456,7 +456,7 @@ VideoJS.player.extend({
this.canPlaySourceResult = false;
return false;
},
- // Check if the extention is compatible, for when type won't work
+ // Check if the extension is compatible, for when type won't work
canPlayExt: function(src){
if (!src) { return ""; }
var match = src.match(/\.([^\.]+)$/);
@@ -1290,10 +1290,10 @@ VideoJS.player.newBehavior("currentTimeS
_V_.addListener(document, "mousemove", this.onCurrentTimeScrubberMouseMove.rEvtContext(this));
_V_.addListener(document, "mouseup", this.onCurrentTimeScrubberMouseUp.rEvtContext(this));
},
- onCurrentTimeScrubberMouseMove: function(event){ // Removeable
+ onCurrentTimeScrubberMouseMove: function(event){ // Removable
this.setCurrentTimeWithScrubber(event);
},
- onCurrentTimeScrubberMouseUp: function(event){ // Removeable
+ onCurrentTimeScrubberMouseUp: function(event){ // Removable
_V_.unblockTextSelection();
document.removeEventListener("mousemove", this.onCurrentTimeScrubberMouseMove, false);
document.removeEventListener("mouseup", this.onCurrentTimeScrubberMouseUp, false);
@@ -1385,11 +1385,11 @@ VideoJS.player.newBehavior("fullscreenTo
}
},
- fullscreenOnWindowResize: function(event){ // Removeable
+ fullscreenOnWindowResize: function(event){ // Removable
this.positionControlBars();
},
// Create listener for esc key while in full screen mode
- fullscreenOnEscKey: function(event){ // Removeable
+ fullscreenOnEscKey: function(event){ // Removable
if (event.keyCode == 27) {
this.exitFullScreen();
}
@@ -1718,7 +1718,7 @@ Function.prototype.evtContext = function
return temp;
};
-// Removeable Event listener with Context
+// Removable Event listener with Context
// Replaces the original function with a version that has context
// So it can be removed using the original function name.
// In order to work, a version of the function must already exist in the player/prototype
More information about the llvm-commits
mailing list