Re: terminology: zero character vs. null character
On 06/03/17 21:15, Roland Illig wrote: Hi, I am currently translating GCC into German. During that, I noticed that in some places the term "zero character" means '\0'. The official term though is "null character", as per the C standard. Since it is confusing to have two different terms for the same concept, the term "zero character" should be dropped entirely, both because it is uncommon and because it can be confused with '0'. Since this affects several places in the code, I think it's better to start a small discussion first instead of writing several PRs. I don't see anything explicit here: https://gcc.gnu.org/codingconventions.html But I believe we follow standards' language and it should always be "null character". Having a discussion first is likely to get nowhere. It sounds too much like "maybe we should" (point 11: https://gcc.gnu.org/wiki/Community). Please send a patch fixing it: https://gcc.gnu.org/wiki/GettingStarted#Basics:_Contributing_to_GCC_in_10_easy_steps You can also send a patch changing https://gcc.gnu.org/codingconventions.html. Once that is accepted, obvious changes to match the coding conventions are usually considered pre-approved. Cheers, Manuel.
Re: GNU Toolchain Fund established at the Free Software Foundation
On 03/10/2017 03:08 AM, David Edelsohn wrote: On Thu, Mar 9, 2017 at 8:48 PM, Ian Lance Taylor wrote: On Thu, Mar 9, 2017 at 11:49 AM, David Edelsohn wrote: As discussed at the last Cauldron, the first interest of the community seems to be the shared infrastructure of Sourceware: hosting, system administration, backups, and updating the websites. There was also a suggestion of funding travel for speakers at the GNU Cauldron, for people who might not be able to afford the travel otherwise. Jim
Right way to represent flag-setting arithmetic instructions in MD files
Hi all, Some (many?) targets have instructions that perform an arithmetic operation and set the condition flags based on the result. For example, on aarch64, we have instructions like ADDS, SUBS, ANDS etc. In the machine description we represent them as a PARALLEL pattern of a COMPARE and the arithmetic operation. For example, the ADDS instruction is represented as: (define_insn "add3_compare0" [(set (reg:CC_NZ CC_REGNUM) (compare:CC_NZ (plus:GPI (match_operand:GPI 1 "register_operand" "%r,r,r") (match_operand:GPI 2 "aarch64_plus_operand" "r,I,J")) (const_int 0))) (set (match_operand:GPI 0 "register_operand" "=r,r,r") (plus:GPI (match_dup 1) (match_dup 2)))] My understanding was that the order of the two in this pattern here doesn't matter because there is an implicit PARALLEL around them, but I found that the compare-elimination pass (compare-elim.c) assumes that the COMPARE set must be in the second position for it to do the transformations it wants. Is there a recommended order for specifying the compare and the arithmetic operation in the MD files? (in which case we should go through the aarch64 MD files and make sure the patterns are written the right way round). Or is the compare-elimination pass just not robust enough? (In which case we should teach it to look into both SETs of the pattern). Thanks, Kyrill
Re: Right way to represent flag-setting arithmetic instructions in MD files
> My understanding was that the order of the two in this pattern here doesn't > matter because there is an implicit PARALLEL around them, but I found that > the compare-elimination pass (compare-elim.c) assumes that the COMPARE set > must be in the second position for it to do the transformations it wants. Why do you want to use the compare-elimination pass exactly if the flags are exposed before reload, as is the case on Aarch64 I think? The combiner is supposed to do the same job instead for these targets. -- Eric Botcazou
Re: Right way to represent flag-setting arithmetic instructions in MD files
On 10/03/17 10:23, Eric Botcazou wrote: My understanding was that the order of the two in this pattern here doesn't matter because there is an implicit PARALLEL around them, but I found that the compare-elimination pass (compare-elim.c) assumes that the COMPARE set must be in the second position for it to do the transformations it wants. Why do you want to use the compare-elimination pass exactly if the flags are exposed before reload, as is the case on Aarch64 I think? The combiner is supposed to do the same job instead for these targets. I'm trying to improve the cases where the result of the arithmetic operation is used in multiple places besides the comparison. For example: add w0, w0, w1 add w1, w0, 2 cmp w0, 0 Combine will not attempt to merge the first ADD and CMP because W0 is used in the second ADD. The compare-elimination pass so far looks like a far simpler place to implement this transformation than combine. Thanks, Kyrill
Re: Right way to represent flag-setting arithmetic instructions in MD files
On Fri, Mar 10, 2017 at 10:10:34AM +, Kyrill Tkachov wrote: > Hi all, > > Some (many?) targets have instructions that perform an arithmetic operation > and set the condition flags based on the result. > For example, on aarch64, we have instructions like ADDS, SUBS, ANDS etc. > In the machine description we represent them as a PARALLEL pattern of a > COMPARE and the arithmetic operation. > For example, the ADDS instruction is represented as: > > (define_insn "add3_compare0" > [(set (reg:CC_NZ CC_REGNUM) > (compare:CC_NZ > (plus:GPI (match_operand:GPI 1 "register_operand" "%r,r,r") >(match_operand:GPI 2 "aarch64_plus_operand" "r,I,J")) > (const_int 0))) >(set (match_operand:GPI 0 "register_operand" "=r,r,r") > (plus:GPI (match_dup 1) (match_dup 2)))] > > My understanding was that the order of the two in this pattern here doesn't > matter because there is > an implicit PARALLEL around them, but I found that the compare-elimination > pass (compare-elim.c) > assumes that the COMPARE set must be in the second position for it to do the > transformations it wants. > > Is there a recommended order for specifying the compare and the arithmetic > operation in the MD files? > (in which case we should go through the aarch64 MD files and make sure the > patterns are written the right > way round). Or is the compare-elimination pass just not robust enough? (In > which case we should teach it > to look into both SETs of the pattern). Please see http://gcc.gnu.org/ml/gcc-patches/2014-12/msg00584.html and surrounding thread. Jakub
Re: Testsuite breakages on Cygwin
On 10 March 2017 at 06:39, Daniel Santos wrote: > Hello, > > I've been trying to get some clean test results on Cygwin and have > encountered a number of problems. I've opened a report for the one I'm most > concerned with (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79867). When an > executable is being loaded, Windows searches for dlls based upon a few silly > ms-like rules (https://msdn.microsoft.com/en-us/library/7d83bc18.aspx), > followed by the PATH environment variable. LD_LIBRARY_PATH is only used in > Cygwin when loading a dll at run-time via dlopen(). This means that ALL > tests are performed by linking in the shared libs that are installed on the > *system* and not those built in the bootstrap. If the dll is not installed > on the system then the test fails. Example: > > FAIL: gfortran.dg/coarray/sync_3.f90 -fcoarray=single -O2 output pattern > test, is > D:/builds/head-test-moutline-x86_64-pc-cygwin/gcc/testsuite/gfortran/sync_3.exe: > error while loading shared libraries: cyggfortran-4.dll: cannot open shared > object file: No such file or directory This is the cause of https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66530
Re: Right way to represent flag-setting arithmetic instructions in MD files
On 10/03/17 10:38, Jakub Jelinek wrote: On Fri, Mar 10, 2017 at 10:10:34AM +, Kyrill Tkachov wrote: Hi all, Some (many?) targets have instructions that perform an arithmetic operation and set the condition flags based on the result. For example, on aarch64, we have instructions like ADDS, SUBS, ANDS etc. In the machine description we represent them as a PARALLEL pattern of a COMPARE and the arithmetic operation. For example, the ADDS instruction is represented as: (define_insn "add3_compare0" [(set (reg:CC_NZ CC_REGNUM) (compare:CC_NZ (plus:GPI (match_operand:GPI 1 "register_operand" "%r,r,r") (match_operand:GPI 2 "aarch64_plus_operand" "r,I,J")) (const_int 0))) (set (match_operand:GPI 0 "register_operand" "=r,r,r") (plus:GPI (match_dup 1) (match_dup 2)))] My understanding was that the order of the two in this pattern here doesn't matter because there is an implicit PARALLEL around them, but I found that the compare-elimination pass (compare-elim.c) assumes that the COMPARE set must be in the second position for it to do the transformations it wants. Is there a recommended order for specifying the compare and the arithmetic operation in the MD files? (in which case we should go through the aarch64 MD files and make sure the patterns are written the right way round). Or is the compare-elimination pass just not robust enough? (In which case we should teach it to look into both SETs of the pattern). Please see http://gcc.gnu.org/ml/gcc-patches/2014-12/msg00584.html and surrounding thread. Thanks, that is helpful. It seems to me that teaching cmpelim to handle either order would not be a very complicated task. Would folks object to making such a change? Kyrill Jakub
Re: Testsuite breakages on Cygwin
On Fri, 10 Mar 2017, Daniel Santos wrote: > 3. Wouldn't it be better to move this logic up into DejaGnu and restrict gcc > to using a black-box interface for modifying the environment? GCC is meant to work with a wide range of different DejaGnu versions. There would be a long gap between adding board-file interfaces for controlling library paths - because that's the right level, interfaces that a board file can define alongside open, close, load, exec, spawn, etc. - and being able to assume they are available. Of course you might try to arrange things so that existing board files not defining such interfaces continue to work (most custom board files are likely to be for bare metal where shared libraries don't exist) and so that GCC continues to work with versions of DejaGnu without such interfaces. Finding shared libraries is generally simpler with installed testing, in that it becomes the responsibility of the board file, site.exp and the rest of the user-provided test environment to arrange for shared libraries to be in locations where they are found automatically. -- Joseph S. Myers jos...@codesourcery.com
Re: diagnostics: %<%s%> vs. %qs
On Fri, 10 Mar 2017, Manuel López-Ibáñez wrote: > On 07/03/17 20:38, Roland Illig wrote: > > Hi, > > > > in the diagnostics the %qs specifier is used in most of the cases. But > > there are some cases left where the more complicated %<%s%> is used. Is > > there a good reason to prefer the complicated spelling? > > > > Same for %<%T%> and %qT, and similar letters. > > 'q' is a flag supported by some format codes but not all. Also, although > different parts of the compiler may support the same format codes (%T), not > all may have support for 'q' yet. Finally, there may be some code using %<%T%> > that predates the existence of '%qT'. The 'q' flag is part of the generic pretty-print.c:pp_format formatting. Thus, everything using the generic pretty-printing can handle the 'q' flag (whereas %T requires a function with support for the tree formats as well as the base class ones). -- Joseph S. Myers jos...@codesourcery.com
Re: Right way to represent flag-setting arithmetic instructions in MD files
On Fri, Mar 10, 2017 at 10:30:33AM +, Kyrill Tkachov wrote: > I'm trying to improve the cases where the result of the arithmetic > operation is used in multiple places besides the comparison. > For example: > add w0, w0, w1 > add w1, w0, 2 > cmp w0, 0 > > Combine will not attempt to merge the first ADD and CMP because W0 is used > in the second ADD. So the LOG_LINK from the first instruction will point at the second, and combining the first and the third isn't considered (because the first and second insns don't combine). combine doesn't try to combine all producer-consumer pairs, only producer with first consumer, because it would not often help and could easily take much more time. On the other hand I'd love to get rid of the LOG_LINKS and use DF directly. Note that combining the first and third insns in your example requires to put the combined insns in the place of the first insn, where normally it would put it at the third insn. Maybe we could treat compares specially? Do such cases happen a lot, btw? Segher
Global AI Big Data Cloud IoT Boot Camp Partners Wanted
Howdy, Would you like to be our Global 2-day AI Big Data Cloud IoT Boot Camp partner in your area? If you can find 30 or plus attendees, provide venue, food, drinks and all other necessary logistics, then we're happy to split the total revenue evenly with you by sending our top-niche industry practitioner as instructor to your area and mission accompolished! We have 20 or so advanced Boot Camps like this one: - Deep Learning Cloud/Container Boot Camp: Build & Operate End-to-End Data Pipeline & Data Lake with TensorFlow, Spark & Hadoop in GUI/API(Python)/CLI(Bash) - www.tinyurl.com/AIBootCamp ( RSVP for 3/11-12 Silicon Valley Event) - www.tinyurl.com/AIBootCamp2 (RSVP for 4/15-16 Silicon Valley Event) - www.tinyurl.com/AIBootCamp2X(RSVP anytime anywhere for a group of 30 - Be our global partner!) - www.hwswworld.com/aibootcampoverview3.pdf - 60-page Boot Camp Overview Slides BTW this is a one-time email, no more if you keep silient Below is the detailed introduction of the above Boot Camp, if you are interested in working with us, please let us know --- You go to a lot of trainings and/or meetups, whether free or not, expensive or cheap, ALL of those are either marketing fluff, sales pitches, or short of global business pictures, or lack of technical details, no insight, let alone foresight. Our 2-day Boot Camp is radically different, vendor agnostic, no strings attached, full of meat, lots of hands-ons, offering you both macro & micro perspective of the state-of-the-art in practical way with hindsight, insight and foresight! What you'll learn, and how you can apply it Learn how Machine & Deep Learning AI Big Data Cloud enables data scientists to help companies reduce costs, increase profits, improve products, retain customers, and identify new opportunities Topics include: How to identify potential business use cases in leveraging big data cloud AI technology How to obtain, clean, and combine disparate data sources to create a data pipeline for data lake What Machine-Learning (Shallow Learning) & Deep Learning technique to use for a particular data science project How to conduct PoC & productionalized big data projects in cloud/container cluster at scale How to create real-time data pipelines using the latest open source with public cloud or private cloud/container, ingest data in real time and at scale, process the data in real-time/interactive/batch, and build data products from real-time data sources How to combines ETL, batch analytics, real-time stream analysis with machine learning, deep learning, and visualizations through both data pipeline & data lakes Understand & master TensorFlow's fundamentals & capabilities Explore TensorBoard to debug and optimize your own Neural Network Architectures, train, test, validate & serve your models for real-life Deep Learning applications at Scale Detailed agend is being listed at www.hwswworld.com and also enclosed here: genda (Subject to Change at Anytime without Notice) - 50% Lecture, 50% Hands-On, Vendor Agnostic, No Strings Attached, You Working on a Cloud/Container Cluster instead of only an Instance/single machine in Cloud/your laptop Day 1 8:00 AM - 8:50AM Elastic Cloud Computing and Scalabe Big Data AI: What, Why and How? 9:00 AM - 9:50AM Deep Dive into Public/Private/Hybrid Cloud Infrastructure: Elastic/Plastic Cloud; Bare Metal/VM/Container; IaaS/PaaS/SaaS; Hyper-Scale/Hyper-Convergence; From Linux Kernel to Distributed System's CAP Theorem; OpenStack as the De facto Private Cloud; Capacity Planning & Auto-scaling Challenges of Cloud; Micro-service-based Immutable Architecture 10:00 AM - 10:50AM Deep Dive into Big Data Technology Stack: Nature of Big Data - Structural/Unstructural; Hot/Warm/Cold; Machine/Human; Text/Numerical, SQL(ACID)/NoSQL(BASE); Batch(Hindsight)/Interactive (Insight)/Streaming(Foresight); Data Pipeline & Datalake; Hadoop/Spark/Kafka/HDFS/HBas/HIVE 11:00 AM - 11:50AM Google/AWS Cloud|Docker/CoreOS Container In-Depth: Computation/Storage/Networking Models 12:00 PM - 1:00PM Lunch Break (Lunch included, Veggie option available) 1:00 PM - 5PM Hands-on: I Set Up & Test Drive Your Own AI Big Data Google/AWS Cloud|CoreOS Container Cluster (Hadoop, Spark, Kafka, HDFS, HBase, HIVE, Tensorflow) : Using Spark for Real-time Word Counting from Kafka Stream of system logs; for Supervised Learning: Regression (Linear) & Classification - Logrithic Regression, Support Vector Machine(SVM), Decision Tree, Random Forest, Naive Bayes, Gradient Boost Tree; for Unsupervised Learning: Clustering using K-Means, Dimension Reduction using Princple Component Analysis (PCA), Dimention Reduction using SVD (Single Value Decomposition); for Recommendation Systems: Collaborative filtering using both implicit & explicit feedback Day 2 8:00 AM - 8:50AM Practical Mac
Ji
Ce Sent from my iPhonezE
Re: Cygwin + zlib
On 02/24/2017 11:55 AM, NightStrike wrote: Currently, to build natively on cygwin, this patch is required to zlib: https://github.com/Alexpux/MSYS2-packages/blob/master/zlib/1.2.11-cygwin-no-widechar.patch Thank you for this. Unfortunately, I didn't see this message prior to filing my bug report, but here it is anyway: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79771 Daniel